Cldr.Number.to_string-exclamation-mark
You're seeing just the function
to_string-exclamation-mark
, go back to Cldr.Number module for more information.
Specs
to_string!( number() | Decimal.t(), Cldr.backend() | Keyword.t() | map(), Keyword.t() | map() ) :: String.t() | no_return()
Same as the execution of to_string/2
but raises an exception if an error would be
returned.
Options
number
is an integer, float or Decimal to be formattedoptions
is a keyword list defining how the number is to be formatted. SeeCldr.Number.to_string/2
Returns
a formatted number as a string or
raises an exception
Examples
iex> Cldr.Number.to_string! 12345, TestBackend.Cldr
"12,345"
iex> Cldr.Number.to_string! 12345, TestBackend.Cldr, locale: "fr"
"12 345"