html-agility-pack
html-agility-pack copied to clipboard
Inconsistency between `node.OuterHtml`, `node.EndNode.OuterHtml`, and `node.Closed`
1. Description
Inconsistency between node.OuterHtml
, node.EndNode.OuterHtml
, and node.Closed
HtmlAgilityPack automatically closes certain nodes. However, when it does, the EndNode
does not get updated accordingly.
Related follow-up questions:
- Is it possible to disable this auto-closing behavior?
- If not, how can one detect if any changes were made to the original HTML?
- Why are there no ParseErrors being logged?
2. Exception
N/A
3. Fiddle or Project
https://dotnetfiddle.net/wDNJfT
From output,
p, <p>Hello, , <>, True
- Endnode is <>
and the <p>
tag is not closed
strong, <strong>world!</strong>, <>, True
- EndNode is <>
even though the OuterHTML has a closing tag