jQuery Linking vs. Download?

前端 未结 6 902
囚心锁ツ
囚心锁ツ 2020-12-09 13:08

Which way is better? To link to the jQuery Pack at http://ajax.googleapis.com. Or to download the appropriate file and link locally? Does it matter? Is there a chance the li

6条回答
  •  旧时难觅i
    2020-12-09 13:50

    I think linking to Google's edge cache servers usually makes sense. Google is almost certainly going to have better up time than you and they are likely to be at least as responsive. Plus, there's the advantage that an incoming user has already cached jQuery from them so they don't have to download it at all.

    The only situation I can think of where I wouldn't do this would be for a site that was primarily used as in intranet, wherein the local copy would truly be local to most visitors (e.g. on the lan).

提交回复
热议问题