jsonx
jsonx copied to clipboard
Option to decode fractional numbers to decimal
New decode option number_format
- when set to decimal
, numbers with exponent or fraction are decoded to erlang-decimal compatible tuple. For original behaviour omit this option or set it to float
{1,12,5} = jsonx:decode(<<"-1.2e6">>, [{number_format, decimal}]).