Permalink
32aaaa6 May 29, 2017
1 contributor

Users who have contributed to this file

29 lines (17 sloc) 603 Bytes

[new] Globalize( locale|cldr )

Create a Globalize instance.

Parameters

locale|cldr

Locale string or Cldr instance of the instance.

Example

Prior to creating any Globalize instance, you must load cldr/supplemental/likelySubtags.json. Read CLDR content if you need more information.

var en = new Globalize( "en" );

// You can optionally omit the `new` operator.
var pt = Globalize( "pt" );

en.formatNumber( 3.1415 );
// > 3.142

pt.formatNumber( 3.1415 );
// > 3,142