• Generator for breadth first tree traversal iteration.

    Type Parameters

    • T

    Parameters

    • root: T
    • children: ((node) => undefined | T[])
        • (node): undefined | T[]
        • Parameters

          • node: T

          Returns undefined | T[]

    • include: ((node) => boolean) = ...
        • (node): boolean
        • Parameters

          • node: T

          Returns boolean

    Returns IterableIterator<T>