4 ms·
>comment support was explicitly removed from JSON for good reasons. >https://plus.google.com/+DouglasCrockfordEsq/posts/RK8qyGVaGSr https://plus.google.com/+Do
by duxup 8y ago
>comment support was explicitly removed from JSON for good reasons.
>https://plus.google.com/+DouglasCrockfordEsq/posts/RK8qyGVaGSr https://plus.google.com/+DouglasCrockfordEsq/posts/RK8qyGVaG...
The link there goes to G+ and thus a dead end. Anyone have that link?
I would have liked to see some alternatives / options that the writer likes.
- ChrisSD 8y agohttps://web.archive.org/web/20120506232618/https://plus.google.com/118095276221607585885/posts/RK8qyGVaGSr https://web.archive.org/web/20120506232618/https://plus.goog... > I removed comments from JSON because I saw people were using them to hold parsing directives, a practice which would have destroyed interoperability. I know that the lack of comments makes some people sad, but it shouldn't. > Suppose you are using JSON to keep configuration files, which you would like to annotate. Go ahead and insert all the comments you like. Then pipe it through JSMin before handing it to your JSON parser. HN discussion is here: https://news.ycombinator.com/item?id=3912149 https://news.ycombinator.com/item?id=3912149
- duxup 8y agoThank you very much.
- Noumenon72 8y agoI am doing my config by reading JSON into Java classes with Jackson. Doing a minify step would mean that I would get the wrong line number in the error message when I forget a comma.
- deleted 8y ago[deleted]