Function processHTML
- processHTML(opts): string
Parameters
- opts: {
containerElement?: string;
firstMatchOnly?: boolean;
html: string;
namespaceURI?: string;
process: ((HTMLElement: any) => void);
selector: string;
}Options
Optional
containerElement ?: stringUse a specific container element.
Optional
firstMatch ?: booleanOnly When true
querySelector
is invoked to process the first matching element only.html: string
The HTML to process.
Optional
namespaceURI?: stringThe namespace URI of the elements to select.
process: ((HTMLElement: any) => void)
The selected element processing function.
- (HTMLElement): void
Parameters
- HTMLElement: any
Returns void
selector: string
The CSS selector query.
Returns string
The processed HTML.
- opts: {
Processes the given HTML by creating by running a CSS selector query with all matched elements being passed through the provided
process
function.