BiSON.js icon indicating copy to clipboard operation
BiSON.js copied to clipboard

JSON compat tradeoffs?

Open mikeal opened this issue 11 years ago • 2 comments

You mention that you aren't 100% compatible with JSON in the README, I'm wondering what those incompatibilities are.

mikeal avatar Jul 03 '13 17:07 mikeal

Hi Mikeal,

those are mostly related to some incompatibilities with UTF16 strings, floating point precision being limited (i.e. not the full precision you would expect from a double) and integers that can only be in the range of 2^-31 - 2^31.

If you want to send user generated data, you probably don't want to use BiSON, but if you know exactly what you're sending (e.g. in a game or some similar application) it's very well suited for that.

BonsaiDen avatar Jul 04 '13 12:07 BonsaiDen

Date objects also appear to have an issue serializing :(

mikeal avatar Jul 04 '13 23:07 mikeal