Interface TreeWalker

The nodes of a document subtree and a position within them.

MDN Reference

interface TreeWalker {
    currentNode: Node;
    filter: NodeFilter;
    root: Node;
    whatToShow: number;
    firstChild(): Node;
    lastChild(): Node;
    nextNode(): Node;
    nextSibling(): Node;
    parentNode(): Node;
    previousNode(): Node;
    previousSibling(): Node;
}

Properties

currentNode: Node
filter: NodeFilter
root: Node
whatToShow: number

Methods

  • Returns Node