Open
Description
- Are you running the latest version?
- Have you included sample input, output, error, and expected output?
- Have you checked if you are using correct configuration?
- Did you try online tool?
Description
According to this XML spec, character references can include leading zeros and lower-case letters in hexadecimal representation.
Personally I encountered this parsing issue by consuming XML provided by a proprietary third-party tool, which includes references in the style of <
.
Input
<?xml version="1.0"?>
<tests>
<test><</test>
<test><</test>
<test><</test>
<test><</test>
<test><</test>
<test><</test>
<test><</test>
<test><</test>
<test><</test>
<test><</test>
</tests>
Code
const parser = new XMLParser();
let result = parser.parse(xmlData, true);
Output
{
"?xml": "",
"tests": {
"test": [
"<",
"<",
"<",
"<",
"<",
"<",
"<",
"<",
"<",
"<"
]
}
}
expected data
{
"?xml": "",
"tests": {
"test": [
"<",
"<",
"<",
"<",
"<",
"<",
"<",
"<",
"<",
"<",
]
}
}
Would you like to work on this issue?
- Yes
Bookmark this repository for further updates. Visit SoloThought to know about recent features.