format.number

Formats a number with custom precision, decimal point and grouped thousands.

Examples

Defaults:

<f:format.number>423423.234</f:format.number>

Output:

423,423.20

With all parameters:

<f:format.number decimals="1" decimalSeparator="," thousandsSeparator=".">423423.234</f:format.number>

Output:

423.423,2

Arguments

decimals

DataType
mixed
Default
‘2’
Required
true
Description
The number of digits after the decimal point

decimalSeparator

DataType
string
Default
‘.’
Required
true
Description
The decimal point character

thousandsSeparator

DataType
string
Default
‘,’
Required
true
Description
The character for grouping the thousand digits