@metreeca/core - v0.9.17
    Preparing search index...

    Function asTag

    • Creates a validated language tag from a string.

      Validates language tags according to BCP 47/RFC 5646.

      Parameters

      • value: string

        The string to convert to a language tag

      Returns string

      The validated language tag

      RangeError If the value is not a valid BCP 47 language tag