@metreeca/trio - v0.1.1
    Preparing search index...

    Function text

    • Encodes a language map as language-tagged or plain literals.

      Important

      By convention the und (undetermined) tag yields a plain Typed literal; every other tag yields a language-Tagged literal.

      Parameters

      • text: Some<{ [tag: string]: Some<string> }>

        The tag-to-content map(s) to encode

      Returns readonly (Tagged | Typed)[]

      The encoded tagged and plain literals

      RangeError On a content string holding an isolated UTF-16 surrogate code point, or on a key that is not a well-formed BCP 47 language tag