javascriptdomapplication-structure

JavaScript file inclusion. Should I not link in <head>?


I'm watching Douglas Crockfords "Theory of the DOM" and he mentioned that the location of my script tags can greatly affect the load time of my applications. Furthermore, he asserts that a script tag should be included as far towards the bottom of the document body as possible.

Is this accurate?

OR

Is this video out of date? (which he actually sites as a reason he didn't lecture on the DOM sooner).


Solution

  • Google agrees with Crockford:

    Yahoo! as well:

    And other SO users agree as well: