apostrophecms / sanitize-html

Clean up user-submitted HTML, preserving whitelisted elements and whitelisted attributes on a per-element basis. Built on htmlparser2 for speed and tolerance
MIT License
3.68k stars 349 forks source link

For wrapper tags, additional tags get added #583

Closed aditigupta50 closed 1 year ago

aditigupta50 commented 1 year ago

<p>hello <p>world</p></p> gets transformed to <p></p>hello <p>world</p><p></p>

boutell commented 1 year ago

Nested paragraph tags are not valid.