We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
In the following lines of htmlparser.js, <a>-tag seems to be classified as a block element.
htmlparser.js
Pure-JavaScript-HTML5-Parser/htmlparser.js
Lines 92 to 96 in 3e8b2b1
But the w3c spec and this summary suggest it should be an inline element instead.
This causes an issue with parsing <a>-tag within an inline element, forcing the latter tag to close before the <a>-tag begins.
Minimal examples:
HTMLtoXML('<div>foo <span>bar</span> buz</div>') // returns "<div>foo <span>bar</span> buz</div>" HTMLtoXML('<span> hi <a href=\"https://www.w3schools.com\">Visit W3Schools.com!</a></span>') //returns "<span> hi </span><a href=\"https://www.w3schools.com\">Visit W3Schools.com!</a>"
The text was updated successfully, but these errors were encountered:
No branches or pull requests
In the following lines of
htmlparser.js
, <a>-tag seems to be classified as a block element.Pure-JavaScript-HTML5-Parser/htmlparser.js
Lines 92 to 96 in 3e8b2b1
But the w3c spec and this summary suggest it should be an inline element instead.
This causes an issue with parsing <a>-tag within an inline element, forcing the latter tag to close before the <a>-tag begins.
Minimal examples:
The text was updated successfully, but these errors were encountered: