jsonx icon indicating copy to clipboard operation
jsonx copied to clipboard

Option to decode fractional numbers to decimal

Open ymv opened this issue 11 years ago • 0 comments

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}]).

ymv avatar Dec 16 '13 08:12 ymv