Function getText

  • Get a node's inner text. Same as textContent, but inserts newlines for <br> tags. Ignores comments.

    Parameters

    • node: AnyNode | AnyNode[]

      Node to get the inner text of.

    Returns string

    node's inner text.

    Use textContent instead.