4 ms·
There seems to be a missing comma in the first grant example. If I am not beffudled. At the end of the dst line. In fact, comma usage seems inconsistent for th
by aatd86 1y ago
There seems to be a missing comma in the first grant example. If I am not beffudled.
At the end of the dst line.
In fact, comma usage seems inconsistent for the last element of some of the nested objects.
To be fair, I don't remember what's the json rule either and would need a quick lookup.
- stavros 1y agoYeah, the example that's missing the commas is wrong, if I'm not mistaken about their json parser. The optional comma at the end is fine with JSON5, which I think they're using, as that allows optional commas, comments, things like that.
- jrockway 1y agoThey use hujson: https://github.com/tailscale/hujson https://github.com/tailscale/hujson But it doesn't accept things like the example that omits an intermediate comma: { "foo": 42 "bar": 123 } > hujson: line 3, column 5: invalid character '"' after object value (expecting ',' or '}')
- orthoxerox 1y agoThey should've gone with Relaxed JSON, which is more relaxed than JSON5, which is more relaxed than HuJSON/JWCC.