I was looking at the MVC 4 release candidate and the default Internet template that is included. I noticed that in the _Layout.cshtml, they are including the jQuery bundle at the bottom of the page:
@Scripts.Render("~/bundles/jquery")
@RenderSection("scripts", required: false)
</body>
</html>
Is there a reason that the script was included at the bottom of the page instead of in the head section with the modernizr script? Are there any benefits to doing it either way? I was always under the impression that you should include your scripts in the head section.
This is generally done for performance. Look at the Yahoo performance guidelines.
http://developer.yahoo.com/performance/rules.html/
They explain why scripts can be better at the bottom.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With