get.md
February 21, 2016 · View on GitHub
.get( path )
Get the item data given its path, or undefined if missing.
| Parameter | Type | Example |
|---|---|---|
| path | String or Array | "/cldr/main/{languageId}/numbers/symbols-numberSystem-latn/decimal"[ "cldr", "main", "{languageId}", "numbers", "symbols-numberSystem-latn", "decimal" ] |
On path parameter, note the leading "/cldr" can be ommited. Also, note that its Array form accepts subpaths, eg. [ "cldr/main", "{languageId}", "numbers/symbols-numberSystem-latn/"decimal" ].
The locale attributes, eg. {languageId}, are replaced with their appropriate values.
If extended with the cldr/unresolved.js module, get the item data or lookup by following locale inheritance, set a local resolved cache if it's found (for subsequent faster access), or return undefined.
ptBr.get( "main/{languageId}/numbers/symbols-numberSystem-latn/decimal" );
// ➡ ","