Interface NodeListOf<TNode>

    interface NodeListOf<TNode> {
        length: number;
        [iterator](): ArrayIterator<TNode>;
        entries(): ArrayIterator<[number, TNode]>;
        forEach(callbackfn: ((value: TNode, key: number, parent: NodeListOf<TNode>) => void), thisArg?: any): void;
        item(index: number): TNode;
        keys(): ArrayIterator<number>;
        values(): ArrayIterator<TNode>;
        [index: number]: TNode;
    }

    Type Parameters

    Hierarchy

    Indexable

    Properties

    length: number

    Returns the number of nodes in the collection.

    MDN Reference

    Methods

    • Performs the specified action for each node in an list.

      Parameters

      • callbackfn: ((value: TNode, key: number, parent: NodeListOf<TNode>) => void)

        A function that accepts up to three arguments. forEach calls the callbackfn function one time for each element in the list.

      • OptionalthisArg: any

        An object to which the this keyword can refer in the callbackfn function. If thisArg is omitted, undefined is used as the this value.

      Returns void

    • Returns the node with index index from the collection. The nodes are sorted in tree order.

      MDN Reference

      Parameters

      • index: number

      Returns TNode