You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
<x value="evil is \"inside"></x> is not parsed properly (to my HTML eyes at least ^^)
I expect to have an attribute with value with value evil is "inside
Instead sax found two attributes, also report some erorrs, due not handling \"
TEST
constsax=require("../sax/sax.js");constparser=sax.parser(true,{lowercase: true,//strictEntities : true});parser.onerror=console.log.bind(console);parser.onopentag=console.log.bind(console);parser.onclosetag=console.log.bind(console);parser.onend=console.log.bind(console);parser.write(`<x value="evil is \"inside"></x>`).close();
output:
Line: 0
Column: 20
Char: i
at error (C:\Users\xe64758\Documents\GitHub\html-formatter\sax\sax.js:667:10)
at strictFail (C:\Users\xe64758\Documents\GitHub\html-formatter\sax\sax.js:693:7)
at Object.write (C:\Users\xe64758\Documents\GitHub\html-formatter\sax\sax.js:1411:13)
at Object.<anonymous> (C:\Users\xe64758\Documents\GitHub\html-formatter\test\test.js:464:8)
at Module._compile (module.js:570:32)
at Object.Module._extensions..js (module.js:579:10)
at Module.load (module.js:487:32)
at tryModuleLoad (module.js:446:12)
at Function.Module._load (module.js:438:3)
at Module.runMain (module.js:604:10)
at run (bootstrap_node.js:393:7)
at startup (bootstrap_node.js:150:9)
at bootstrap_node.js:508:3
Error: Invalid attribute name
Line: 0
Column: 26
Char: "
at error (C:\Users\xe64758\Documents\GitHub\html-formatter\sax\sax.js:667:10)
at strictFail (C:\Users\xe64758\Documents\GitHub\html-formatter\sax\sax.js:693:7)
at Object.write (C:\Users\xe64758\Documents\GitHub\html-formatter\sax\sax.js:1346:13)
at Object.<anonymous> (C:\Users\xe64758\Documents\GitHub\html-formatter\test\test.js:464:8)
at Module._compile (module.js:570:32)
at Object.Module._extensions..js (module.js:579:10)
at Module.load (module.js:487:32)
at tryModuleLoad (module.js:446:12)
at Function.Module._load (module.js:438:3)
at Module.runMain (module.js:604:10)
at run (bootstrap_node.js:393:7)
at startup (bootstrap_node.js:150:9)
at bootstrap_node.js:508:3
Error: Attribute without value
Line: 0
Column: 27
Char: >
at error (C:\Users\xe64758\Documents\GitHub\html-formatter\sax\sax.js:667:10)
at strictFail (C:\Users\xe64758\Documents\GitHub\html-formatter\sax\sax.js:693:7)
at Object.write (C:\Users\xe64758\Documents\GitHub\html-formatter\sax\sax.js:1337:13)
at Object.<anonymous> (C:\Users\xe64758\Documents\GitHub\html-formatter\test\test.js:464:8)
at Module._compile (module.js:570:32)
at Object.Module._extensions..js (module.js:579:10)
at Module.load (module.js:487:32)
at tryModuleLoad (module.js:446:12)
at Function.Module._load (module.js:438:3)
at Module.runMain (module.js:604:10)
at run (bootstrap_node.js:393:7)
at startup (bootstrap_node.js:150:9)
at bootstrap_node.js:508:3
{ name: 'x',
attributes: { value: 'evil is ', inside: 'inside' },
isSelfClosing: false }
x
The text was updated successfully, but these errors were encountered:
I'm running into this issue trying to parse a JSON string value: ...<data>{"USER":[{"NAME":"Bar, Foo<span class=\"icon\">User</span>"}]}</data>...
I get the error pointing to the \".
Hi,
<x value="evil is \"inside"></x>
is not parsed properly (to my HTML eyes at least ^^)I expect to have an attribute with
value
with valueevil is "inside
Instead sax found two attributes, also report some erorrs, due not handling
\"
TEST
The text was updated successfully, but these errors were encountered: