formatCurrency

The

formatCurrency
function is used to transform numbers into currencies.

Do's & Don'ts

Don't use it if you can use the Currency component.

Params

Name
Type
Default
Description
value*
number
The value that is being formatted
locale
sv-SE
sv-SE
The locale used to format

Returns

string
: Formatted currency

Examples