Yet another try/catch for JSON#parse. This one returns your custom error token value in case of a SyntaxError (default: undefined), and passes all other errors to your custom error handler (default: re-throw).
JSON.parse with context information on error
Parse JSON with more helpful errors
JSON.parse with context information on error
JSON parse with prototype poisoning protection
Parse HTTP Content-Type header according to RFC 7231
Parse and stringify JSON with comments. It will retain comments even after saved!
Big-friendly JSON. Asynchronous streaming functions for large JSON data sets.
Parse, Resolve, and Dereference JSON Schema $ref pointers
Parse a JSON string that has git merge conflicts, resolving if possible
Parse partial JSON generated by LLM
Parse json safely and at max speed
A super light and fast circular JSON parser.
Encode/decode circular structures for converting to and from JSON.
hast utility to create an element from a simple CSS selector
Parse JSON safely without throwing
A set of efficient utilities that extend the use of JSON (streaming, estimate size, NDJSON/JSONL, etc.)
Parse JSON without risk of losing numeric information
Read and parse a JSON file
Parser adapter for parsing JSON documents into base namespace.
decycle your json
Parse, Resolve, and Dereference JSON Schema $ref pointers
JSON AST parser, tokenizer, printer, traverser.
Parser adapter for parsing JSON documents into OpenAPI 2.0 namespace.