From 64b3b318a0557d65c3d8286e3572c58a33c1f447 Mon Sep 17 00:00:00 2001 From: Evan You Date: Thu, 21 Apr 2016 15:31:15 -0400 Subject: [PATCH] fix html attribute escape in Safari --- src/compiler/parser/html-parser.js | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) diff --git a/src/compiler/parser/html-parser.js b/src/compiler/parser/html-parser.js index ea33929f..a6c1d70e 100644 --- a/src/compiler/parser/html-parser.js +++ b/src/compiler/parser/html-parser.js @@ -8,11 +8,6 @@ import { decodeHTML } from 'entities' import { makeMap } from '../../shared/util' -// PhantomJS encodes attribute values when retriving outerHTML. -const inPhantomJS = - typeof navigator !== 'undefined' && - navigator.userAgent.indexOf('PhantomJS') > -1 - // Regular Expressions for parsing tags and attributes const singleAttrIdentifier = /([^\s"'<>\/=]+)/ const singleAttrAssign = /=/ @@ -242,7 +237,7 @@ export function parseHTML (html, handler) { var value = args[3] || args[4] || (args[5] && fillAttrs(args[5]) ? args[1] : '') return { name: args[1], - value: inPhantomJS ? decodeHTML(value) : value + value: decodeHTML(value) } })