1

Below is a quote from one of the Yahoo performance pages:

While a script is downloading, however, the browser won't start any other downloads, even on different hostnames.

When I look at page load of our website, I can see that many scripts are being downloaded at the same time:

enter image description here

Am I mistaken, or should the quote should instead read like this?

While scripts are downloading (there can be several scripts downloading at the same time), the browser won't start any other downloads, even on different hostnames.

5

Depending on the browser you use, that may be correct. As javascript may alter the page content, add new dom elements etc., the execution of anything after one script is blocked until that script gets executed. Nevertheless the download of other resources may happen in parallel.

The best advice is to put script tags in the bottom of your body and pack them together to minimize the communication overhead of multiple requests. Steve Sounders has written two good books about all this called "High performance websites" and "Even faster websites".

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.