fb55/htmlparser2

Self closing tags with periods in their name are parsed nested instead of as siblings

jonas-k opened this issue · 2 comments

Code like this has the wrong tree structure after parsing:

<Parent.Element>
    <Child.Element name="first"/>
    <Child.Element name="second"/>
    <Child.Element name="third"/>
</Parent.Element>

The resulting structure is:

<Parent.Element>
    <Child.Element name="first">
        <Child.Element name="second">
            <Child.Element name="third">
</Parent.Element>
fb55 commented

Try enabling xmlMode!

Thank you for the quick response. Enabling xmlMode solved the problem.