Do I have to include respond.js in the header?

我们两清 提交于 2020-01-04 04:26:18

问题


Building a website using Bootstrap3 and I would like for it to work on IE. It seems to be working when I do include respond.js at the bottom of the page but I would like to make sure this is in fact true before I go live with it.

My question is simply, does it matter where I include my JS files specifically respond.js?


回答1:


From the GitHub page it says:

Reference the respond.min.js script (1kb min/gzipped) after all of your CSS (the earlier it runs, the greater chance IE users will not see a flash of un-media'd content)




回答2:


It is advised to include java scripts at the bottom of the page, but because we assume they have no effect on the first look of the page, and we want the users see some thing as fast as possible, so the page will get render and then the javascripts will be, but if the look of the website depends on the javascript library it should be in the header for a better users experience, libraries like modernizr respond and so on



来源:https://stackoverflow.com/questions/18680215/do-i-have-to-include-respond-js-in-the-header

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!