2 ms·
I agree. SGML/XML was invented for representing and editing semistructured text, not as generic data serialization format. In markup text, attributes are for da
by tannhaeuser 8y ago
I agree. SGML/XML was invented for representing and editing semistructured text, not as generic data serialization format. In markup text, attributes are for data that isn't to be rendered itself, but for specifying how rendering should be performed and other things (how CSS fans thought it would be a good idea to make up an entire new ad-hoc language for this purpose, then reclaiming "HTML is for content not presentation" is another discussion). But the NoXML/JSON folks haven't really come up with a widely used alternative to eg. XML Schema (which isn't surprising since JavaScript isn't statically typed). The majority of the work where standardization of message payloads is useful (such as for parties in e-Commerce) has already been carried out. The world hasn't and couldn't have waited for JSON to become a viable alternative. Besides, what makes JSON so practical - that it is schema-less - is exactly the reason it isn't a good fit for describing upfront protocols for long-term multi-party data exchange.