vlocode-project - v1.40.0-beta-4
    Preparing search index...

    Function getRootTagName

    • Get the name of the root element of a XML string excluding the XML deceleration:

      <!-- Returns name of first none-comment root tag: rootTag -->
      <rootTag>
      <inner />
      </rootTag

      Parameters

      • xml: string | Buffer<ArrayBufferLike>

        XML string or buffer

      • Optionaloptions: { requireDeclaration?: boolean }
        • OptionalrequireDeclaration?: boolean

          When true the function will return undefined when the XML string does not start with a XML declaration

      Returns undefined | string

      Name of the root tag in the XML file