Skip to content

Commit

Permalink
fix: decode single quotes in html attributes (vuejs#9341)
Browse files Browse the repository at this point in the history
  • Loading branch information
bughit authored and Lostlover committed Dec 10, 2019
1 parent 9881823 commit b6252dc
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions src/compiler/parser/html-parser.js
Expand Up @@ -36,10 +36,11 @@ const decodingMap = {
'"': '"',
'&': '&',
'
': '\n',
'	': '\t'
'	': '\t',
''': "'"
}
const encodedAttr = /&(?:lt|gt|quot|amp);/g
const encodedAttrWithNewLines = /&(?:lt|gt|quot|amp|#10|#9);/g
const encodedAttr = /&(?:lt|gt|quot|amp|#39);/g
const encodedAttrWithNewLines = /&(?:lt|gt|quot|amp|#39|#10|#9);/g

// #5992
const isIgnoreNewlineTag = makeMap('pre,textarea', true)
Expand Down

0 comments on commit b6252dc

Please sign in to comment.