Why does Amazon have so much free HTML space?

If you look at the home page source, somewhere around 14 newlines before the DOCTYPE. For registered pages in Sales Central, I see over 400! There will often be 20 newlines between the page components, and sometimes much more.

To show that I am not doing this:

A screenshot of Chrome's source viewer, displaying the DOCTYPE declaration on the 445th line.

Amazon seems to be fanatical about speed, so I am incredulous if they would do this unintentionally, especially before DOCTYPE. (Everything else could be a nicely formatted FOR loop that chooses not to show any pattern on each iteration maybe?)

Can they initiate a connection before the application logic is ready to start spitting out code and "streams" of some whitespace?

+3


source to share


2 answers


I recommend that you contact Amazon at your request, as only they can provide a valid answer to your question. Below is the link to the Contact Us page:

https://www.amazon.com/gp/help/contact-us/general-questions.html?skip=true



Hope it helps.

+2


source


I guess they are trying to spoof the short first byte response time.

Many speed tests on the Internet (ej: http://www.webpagetest.org ) rate the fast first byte sent to the browser favorably, perhaps search engines also rate this metric as it is considered a small "processing time".



Printing some white space while calculating the page content quickly forces something in the browser and can cut the "first byte" time from 0.5 to 0.0 seconds.

Or maybe it's just a mistake :)

+1


source







All Articles