Closed yfools closed 7 months ago
As per documentation... :slightly_smiling_face:
After sanitizing your markup, you can also have a look at the property DOMPurify.removed and find out, what elements and attributes were thrown out. Please do not use this property for making any security critical decisions. This is just a little helper for curious minds.
https://github.com/cure53/DOMPurify?tab=readme-ov-file#okay-makes-sense-lets-move-on
We try to put all removed elements in there, including the risky ones - but there is no strong guarantee that nothing in this array means the SVG was safe.
I observed that DomPurify provides some hooks and a Removed, but I don't know which elements are put in Removed because of security risks and which are just formatted