Function getParent

Get a node's parent.

  • Parameters

    • elem: AnyNode

      Node to get the parent of.

    Returns ParentNode | null

    elem's parent node, or null if elem is a root node.