If the script tag is above or below the body in a HTML page, does it matter for the performance of a website?
And what if used in between like this:
So I know this is an old discussion, but I've been reading about this topic and reading other answers on StackOverflow...
It actually doesn't matter where you put the jQuery tag anymore:
Finally, a word about persistent folklore. You may have encountered the frequently repeated advice to “always place JavaScript at the bottom of the page just before the closing tag”. This was once true because web browsers loaded scripts sequentially and blocked loading and rendering until each script was complete. This is no longer true; modern browsers do “preload scanning” and begin loading all scripts in parallel, whether listed in the head element or at the bottom of the page. External JavaScript often is loaded asynchronously and is written so it won’t execute until the page is loaded and the DOM is ready. Loading a script in the head element is no longer a bad practice.
http://railsapps.github.io/rails-javascript-include-external.html