tulios / json-viewer

It is a Chrome extension for printing JSON and JSONP.
https://chrome.google.com/webstore/detail/json-viewer/gbmdgpbipfallnflgajpaliibnhdgobh
MIT License
3.29k stars 672 forks source link

JS precision lost #324

Open threetown opened 1 year ago

threetown commented 1 year ago

input:

{"sid":822106502566256641}

output:

{"sid": 822106502566256600}

How to fix this bug?

c-dante commented 1 year ago

Not a bug -- js uses ieee doubles for all numbers. Use a string or big number to represent large integers.