- cross-posted to:
- [email protected]
- cross-posted to:
- [email protected]
There exists a peculiar amnesia in software engineering regarding XML. Mention it in most circles and you will receive knowing smiles, dismissive waves, the sort of patronizing acknowledgment reserved for technologies deemed passé. “Oh, XML,” they say, as if the very syllables carry the weight of obsolescence. “We use JSON now. Much cleaner.”


It’s true, though, that JSON is just better for most applications.
Except config files. Please don’t do config files in json.
Yaml
Fuck yaml. TOML or literally anything else.
Json configs read much cleaner to me since .net swapped to them a while back.
Xml is incredibly verbose when there’s a 12k loc web.config.xml
Then do a cfg or ini style config or make multiple config files. YAML/TOML if you can’t make it simpler. The neccessity for complex config formats is a fuckup of the dev.
Why not? It works great in Python.
Not on the human parser side.
JSON is super easy to read and write though. Just needs a parser that allows comments…
And no comments, unless you use a non-standard parser. But then you might as well use anorher format.
This only works if the software that consumes the JSON doesn’t validate it or ignores keys it doesn’t recognize (which is bad, IMHO).
Lol. That works, but its hacky.
The meaning of a “comment” is an integrated language feauture to write something that is not parsed by that language. This is just regular JSON.