The library aims to be a replacement for the classic JSON format/syntax and take advantage of the new features found in EcmaScript 5.
Here are some key features of "JSON5":
· Support inline (single-line) and block (multi-line) comments
· Support for hexadecimal (base 16) numbers
· Support for single-quoted strings
· Support for trailing commas after objects and arrays
· Split strings across multiple lines
What's New in This Release: [ read full changelog ]
· Support leading decimal points in decimal numbers.
· Support hexadecimal numbers.
· Add Node.js require() hook. Require json5/lib/require to register it.
· Add Node.js executable to compile JSON5 files to JSON. Run with json5.
· Rejects octal numbers properly now.