Probably because it is not intended to be read by humans. JSON parsers will have no problem with lack of irrelevant white space, so why bother adding white space?
Yes, I fully appreciate that it doesn't matter for parsers. But, still, when I have to write some JSON or some HTML, I usually prefer to insert at least some vertical space (EOLs), because there is almost always a time somewhere in the future when I or another human will need to read the source or change it. My take on this is similar to what I do with Perl or C code: to make it friendly to the human reader. But I certainly understand your point that you may also need to optimize your document's size, especially if it's going to be transmitted zillions of times over a network which may sometimes be slow.

In reply to Re^3: parse html for specific things by Laurent_R
in thread parse html for specific things by Gtforce

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post, it's "PerlMonks-approved HTML":



  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.