JSON support for BigInt in Chrome/V8
anders.rundgren.net at gmail.com
Sat Jul 28 15:52:14 UTC 2018
On 2018-07-28 16:52, Ranando King wrote:
> Why not just use DataURL syntax, something like this:
> "field1": "data:json/bigint,12345678901234567890123456789012345678901234567890123456789012345678901234567890",
> This way, even as other objects pop up to be serialized, all that would be needed is another mime type in the format "json/<typename>". I could even see letting the "<typename>" portion hold the non-lowercased, original class name to make it even faster to deserialize such fields without knowing all possible mime types in advance. Still 100% compatible with existing JSON. Still 100% human readable/writable. Very easy to implement, and self consistent.
I think the issue is rather: What problem do we want to solve?
It is pretty obvious that there is no "perfect" solution.
More information about the es-discuss