5 ms·
And here I thought everyone hated XML...
by armored_mammal 14y ago
And here I thought everyone hated XML...
- georgemcbay 14y agoI don't hate XML, I just think it tends to be misused. I (still) think XML is fine for configuration files and things like markup of UI/UX components (See: Flex, WPF, Android layouts, etc). In this context, where you may be modelling the relationship between many parents with many children nested fairly deeply, I find XML much more readable and easy to edit and reason about than JSON. Where XML makes little sense is as an over-the-wire network protocol format or in any context where its "human readable"/"human editable" properties aren't as important. In those contexts, I think JSON is far better suited though neither is completely ideal.
- GlennS 14y agoI'm not keen on XML for configuration files, it's just too full of junk to read quickly.
- DougWebb 14y agoI don't think XML is good at all for config files or UI/UX component markup, but for me that's mostly because of the end tags. Other formats, such as YAML, are able to describe hierarchical data without the verbosity of end tags, and I think that makes the files much more readable. In fact, I think it's fair to say that WPF and all of Microsoft's config and resource file formats inherit their use of XML from mimicry of the Java ecosystem when C# and .NET were being developed as an alternative stack to Java. Android's inheritance is more direct, since it's based on the Java ecosystem. And as we all know, the crazy hype phase that XML went through was hand-in-hand with the crazy hype phase that Java went through. If Java hadn't happened, XML probably still would have as an improvement over SGML, but it probably would have remained the simple document markup language that it's pretty good for rather than becoming the "XML Everywhere" beast.