Pre-defined format specifiers for use with utilities/format/number!format.

Enumeration Members

ACCOUNTING

Same as CURRENCY, except that negative values are displayed in parentheses instead of using a "-" sign.

CURRENCY

A localized representation of a monetary amount in a specific currency (e.g. "$123.45" for USD, "£123.45" for GBP for en-US locale).

DEFAULT

The default representation for number values (equivalent to FIXED_POINT).

FIXED_POINT

A localized representation of a number with a decimal separator (e.g. "12345.67", "-42" for en-US locale).

NUMBER

A localized representation of a number with a decimal separator and group separators (e.g. "12,345.67", "-42" for en-US locale).

PERCENT

A localized representation of a percentage (e.g. 0.99 -> "99%" in the en-US locale).

ROUND_TRIP

An invariant representation of a number (e.g. "12345.67"). Guarantees that the number can be parsed back into the same number, regardless of locale.