forked from sindresorhus/lcid
-
Notifications
You must be signed in to change notification settings - Fork 0
/
index.d.ts
44 lines (34 loc) · 1.08 KB
/
index.d.ts
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
import lcidCodes = require('./lcid.json');
declare const lcid: {
/**
Get a [standard locale identifier](https://en.wikipedia.org/wiki/Locale_(computer_software)) from a [Windows locale identifier (LCID)](http://en.wikipedia.org/wiki/Locale#Specifics_for_Microsoft_platforms).
@example
```
import lcid = require('lcid');
lcid.from(1044);
//=> 'nb_NO'
```
*/
from(lcidCode: number): string;
/**
Get a [Windows locale identifier (LCID)](https://en.wikipedia.org/wiki/Locale#Specifics_for_Microsoft_platforms) from a [standard locale identifier](https://en.wikipedia.org/wiki/Locale_(computer_software)).
@example
```
import lcid = require('lcid');
lcid.to('nb_NO');
//=> 1044
```
*/
to(localeId: string): number;
/**
Mapping between [standard locale identifiers](https://en.wikipedia.org/wiki/Locale_(computer_software)) and [Windows locale identifiers (LCID)](http://en.wikipedia.org/wiki/Locale#Specifics_for_Microsoft_platforms).
@example
```
import lcid = require('lcid');
lcid.all;
//=> {'af_ZA': 1078, …}
```
*/
readonly all: typeof lcidCodes;
};
export = lcid;