Lokalized JavaScript — Version 1.0.0
    Preparing search index...

    Function forAcceptLanguage

    • Create per-call translation options by negotiating an Accept-Language header. Unusable input produces an unmatched result (locale: null, matchType: "none"), so the runtime uses its configured fallback while preserving that diagnostic.

      The raw header is limited to 4,096 UTF-16 code units and the parsed list to 32 ranges, including IANA equivalents. Oversized lists are rejected as a whole; no preferences are retained in the unmatched result.

      Parameters

      • negotiator: LocaleMatcher
      • acceptLanguage: string | null | undefined

        the raw, already-combined field value

      Returns Readonly<{ localeMatchResult: LocaleMatchResult }>