If you're looking for a solution to handle large integers in JSON objects, my library might be just what you need. Check it out here: https://www.npmjs.com/package/json-with-bigint
Here's an example of how you can use it:
import { JSONParse } from 'json-with-bigint';
const yourJSON = `{"someValue":42,"someBigValue":10000000000000000365}`;
JSONParse(yourJSON); // { someValue: 42, someBigValue: 10000000000000000365n }
The library is smart enough to detect BigInt values automatically, so there's no need to specify which keys contain BigInt values.
Additionally, it provides consistent round-trip operations (parse - stringify - parse). This means that the values you deserialize will be identical to the ones you initially serialized, and vice versa.
import { JSONParse, JSONStringify } from 'json-with-bigint';
const yourJSON = `{"someValue":42,"someBigValue":10000000000000000365}`;
JSONParse(yourJSON); // { someValue: 42, someBigValue: 10000000000000000365n }
JSONStringify(data); // '{"someValue":42,"someBigValue":10000000000000000365}'
JSONParse(JSONStringify(data)); // { someValue: 42, someBigValue: 10000000000000000365n }