News for hackers. Stuff that matters.
Re:Why is JSON so popular? Developers want out of the syntax... by jbooth on Friday March 19, 2010 @11:33AM (#1204340)
Well, in XML you're prone to files like (lets see how news.yc renders this):

<thingies> <thingy> <name>thingy1</name> </thingy> <thingy> ... </thingies>

I've seen that a billion times, if you're doing DOM, you have to pull that whole thing into memory and then run over it again. Most JSON-based storage systems I've seen recently are more record based so you can stream it through.

So I guess my beef on that one isn't specifically with XML, you could split the above snippet into separate entities.. but I'll note that it still involves about 90% markup and 10% data. Not exactly the most efficient thing possible.

There are no comments on this comment yet.