logoalt Hacker News

bawolff12/08/20246 repliesview on HN

As much as i like this (yaml goes way too far, but trailing commas and comments would make json much nicer. I actually think this spec goes too far with single quotes) i hate that it is named json5. I think its unethical to imply you are the next version of something if you don't have the blessing of the original author.


Replies

Dylan1680712/08/2024

Even when the original author said it was "discovered"?

JSON5 is closer to "javascript object notation" than JSON itself. It's partly an update and partly a removal of arbitrary restrictions.

show 1 reply
papa-whisky12/08/2024

I think the name just means that it sits in-between JSON and ES5 (i.e., it's a superset of JSON and subset of ES5).

edit: well as this comment thread indicates, the name is pretty confusing for everyone :)

yonran12/09/2024

The parser for tsconfig.json (typscript.parseConfigFileTextToJson(fileName, jsonText) or parseJsonText) seems to be what you want; I wonder if there is a name for that format.

show 1 reply
wvh12/09/2024

Could also be construed as paying homage, though. I think the number 5 here is a reference to congruence with ECMA Script 5 rather than to imply a version of JSON.

The_Colonel12/09/2024

Single quotes are useful for string contents containing many double quotes (e.g. XML).

show 1 reply
j1elo12/08/2024

I always thought that the name JSON5 pretends to be nothing more than a pun on Michael Jackson's original band, The Jackson 5. It sounds too similar!

If it didn't originate from that, what else?

show 3 replies