new IntlNumberFormat(locale, options)
Represents language sensitive number formatter based on Intl.NumberFormat
(https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/NumberFormat)
Parameters:
Name | Type | Argument | Default | Description |
---|---|---|---|---|
locale |
string |
<optional> |
'en' | The locale. |
options |
Intl.NumberFormatOptions |
<optional> |
The format options. See https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/NumberFormat |
Example
var options = { minimumFractionDigits: 4, maximumFractionDigits: 4 }; var format = new StockChartX.IntlNumberFormat(options);
Extends
Members
-
locale :string
-
The locale string (e.g. 'en-US').
Type:
- string
- Inherited From:
-
options :Intl.ResolvedNumberFormatOptions
-
Gets/Sets format options (https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/NumberFormat)
Type:
- Intl.ResolvedNumberFormatOptions
Methods
-
setDecimalDigits(value)
-
Sets number of decimal digits to display.
Parameters:
Name Type Description value
number Number of decimal digits.