setHTMLUnsafe

fun setHTMLUnsafe(html: TrustedHTML, options: SetHTMLUnsafeOptions = definedExternally)(source)

The setHTMLUnsafe() method of the ShadowRoot interface can be used to parse HTML input into a DocumentFragment, optionally filtering out unwanted elements and attributes, and then use it to replace the existing tree in the Shadow DOM.

MDN Reference


fun setHTMLUnsafe(html: String, options: SetHTMLUnsafeOptions = definedExternally)(source)