Vloop API
    Preparing search index...

    Function getJsonTagValue

    • Reads the first matching tag with JSON.parse().

      Parameters

      • text: unknown

        Text to search. Falsy values are treated as empty text.

      • tagName: string

        Tag name, with or without angle brackets.

      • Optionaloptions: { fallback?: unknown; required?: boolean } = {}
        • Optionalfallback?: unknown

          Returned for a missing tag or invalid JSON.

        • Optionalrequired?: boolean

          Throws when the tag is missing. Defaults to false.

      Returns unknown