Skip to main content

HTMLSourceDom

export
interface HTMLSourceDom {
  baseUrl?: string;
  dom: Element | Document;
}

A source which content is a DOM tree created by the transient render engine parseDocument method.

See ​useAmbientTRenderEngine.

Remarks

When you use a DOM source, the onHTMLLoaded callback will never be invoked for this source, since the source loader hasn't access to the HTML source of the DOM.

Fields#

baseUrl#

optional
baseUrl?: string;

The base URL to resolve relative URLs in the HTML code. See ​useNormalizedUrl.

dom#

required

A DOM object. This object must have been created with the transient render engine parseDocument method.