Function findAll

  • findAll(test: ((elem: Element) => boolean), nodes: AnyNode[]): Element[]
  • Search an array of nodes and their children for elements passing a test function.

    Same as find, but limited to elements and with less options, leading to reduced complexity.

    Returns

    All nodes passing test.

    Parameters

    • test: ((elem: Element) => boolean)

      Function to test nodes on.

        • (elem: Element): boolean
        • Parameters

          • elem: Element

          Returns boolean

    • nodes: AnyNode[]

      Array of nodes to search.

    Returns Element[]