logoalt Hacker News

yosito • 12/09/2024 • 3 replies • view on HN

Except that JSON is a valid JavaScript object, and JSON5 is not.


Replies

Zamicol • 12/09/2024

Why is it not? My understanding is that it is a valid ES5 and forward object.

ahartmetz • 12/09/2024

Unless there's a direct lie in the description of JSON5 ("subset of ECMAScript"), JSON5 objects are valid JS objects.

tubthumper8 • 12/09/2024

Can you provide an example?