Unsanitized HTML parsing methods
Widely availableThe Document.parseHTMLUnsafe()
static method parses HTML into a DOM tree, while the setHTMLUnsafe()
method of Element
and ShadowRoot
parses and inserts HTML into an existing tree. No sanitization applies to these methods, so never call them with user-provided HTML strings.
Safari Browser
iOS
17.4