@designliquido/xpath
    Preparing search index...

    Function getFirstItem

    • Extracts the first item from a sequence (XPath 1.0 first-item-only semantics).

      When XPath 1.0 compatibility mode is enabled, sequences are treated as node-sets containing only the first node. This function extracts that first item.

      Parameters

      • sequence: any

        The sequence or single value

      Returns any

      The first item, or null if empty sequence