问题描述
可能有百分之几的浏览器已经加载了Google的JQuery缓存版本?
我要这是要弄清楚我的页面在平均"浏览器上的加载速度.我的页面需要JQuery和JQuery UI.我相信大多数浏览器可能已经从Google的服务器中缓存了JQuery.这是真的?以及JQuery UI的数字是什么?
I am asking this to figure out how fast my page would load on an "average" browser. My page needs both JQuery and JQuery UI. I believe most browsers would probably have JQuery already cached from Google's servers. Is this true? And what are the numbers for JQuery UI?
任何证明您的主张都会有所帮助.
Any proof of your claim would be helpful.
此外,对于Jquery UI:Google的Jquery UI有哪些组件?是全部还是全部(排序等)?
Also, for Jquery UI:What components does Google's Jquery UI have? Does it have all of them or just a few (sortable, etc...)?
此外,我认为它约为180 kb.我应该使用它还是应该在jqueryui.com上创建一个较小的custom.ui.min?
Also, I think it's about 180 kb. Should I use that or should I create a custom.ui.min at jqueryui.com that might be smaller?
推荐答案
根据最佳做法加快网站速度:
这很重要,因为对于40-60%的每日访问者而言,无论从何处加载jQuery库都没有关系,他们不会将其存储在缓存中.
This is relevant because for 40-60% of your daily visitors, it doesn't matter where you load the jQuery library from, they won't have it in their cache.
我还认为,问题的实质还在于访问者将其缓存的频率.您是否要依赖一个不受您控制的外部公司,甚至与Google一样大?如果Google倒闭(发生了该怎么办)怎么办?如果Google在您长时间休假时突然决定停止托管jQuery,该怎么办?如果Google员工犯了一个错误并用新版jQuery覆盖了您指定的版本,该新版jQuery破坏了您页面上的功能,怎么办?
I also think there is more to the question then how often your visitors will have it cached. Do you want to take a dependency on an outside company you do not control, even one as large as Google? What if Google is down (it has happened)? What if Google suddenly decides to stop hosting jQuery while you are on an extended vacation? What if a Google employee makes a mistake and overwrites your specified version with a new version of jQuery that breaks functionality on your page?
这篇关于已加载Google的JQuery缓存版本的浏览器的百分比是多少?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!