Documentation
    Preparing search index...
    interface Local<T> {
        get(node: Element): T | undefined;
        remove(node: Element): boolean;
        set(node: Element, value: T): T;
        toString(): string;
    }

    Type Parameters

    • T
    Index
    • Retrieves a local variable stored on the node (or one of its parents).

      Parameters

      Returns T | undefined

    • Deletes the value associated with the given node. Values stored on ancestors are not affected, meaning that child nodes will still see inherited values.

      This function returns true if there was a value stored directly on the node, and false otherwise.

      Parameters

      Returns boolean

    • Store a value for this local variable. Calling .get() on children of this node will also retrieve the variable's value.

      Parameters

      • node: Element

        A node element.

      • value: T

        Value to store locally

      Returns T

    • Obtain a string with the internally assigned property name for the local which is used to store the value on a node

      Returns string