v149 · JavaScript · demo
Locale Inspector
Parse any BCP 47 locale tag and inspect all its components — including the new .variants array from Chrome 149.
Checking support…
| Property | Value | Notes |
|---|
// Chrome 149+: Intl.Locale.prototype.variants returns an array
const locale = new Intl.Locale('sl-rozaj-biske');
console.log(locale.language); // 'sl'
console.log(locale.variants); // ['rozaj', 'biske'] ← new in Chrome 149
// Previously: variants was undefined
// locale.variants === undefined (Chrome 148 and earlier)
see also
- Variant Builder — construct locales with variants
- Back to feature index
- ChromeStatus entry
implementation reference
Need the exact API surface, compatibility boundaries, errors, lifecycle, and source links? Read the matching gendn reference ↗