DomHandler
class DomHandler { }
constructor(
callback?: Callback | null,
options?: DomHandlerOptions | null,
elementCB?: ElementCallback,
);private readonly callback;
private done;
private readonly elementCB;
private readonly options;
private parser;
dom: Node[];
root: Document;
protected handleCallback(error: Error | null): void;
oncdataend(): void;
oncdatastart(): void;
onclosetag(): void;
oncomment(data: string): void;
oncommentend(): void;
onend(): void;
onerror(error: Error): void;
onopentag(name: string, attribs: {}): void;
[key: string]: string;
onparserinit(parser: ParserInterface): void;
onprocessinginstruction(name: string, data: string): void;
onreset(): void;
ontext(data: string): void;
§Constructors
§
new DomHandler(callback?: Callback | null, options?: DomHandlerOptions | null, elementCB?: ElementCallback)
[src]@param callback
Called once parsing has completed.
@param options
Settings for the handler.
@param elementCB
Callback whenever a tag is closed.
§Properties
§
tagStack: NodeWithChildren[]
[src]Stack of open tags.