Why worry about google CDN APIs

http://code.google.com/apis/libraries/devguide.html states that you need to register to use the API to use CDN. But why? You can explicitly use it without.

Does google.com/blah/jquery.js?myAPIcode link to download the new version of jquery.js instead of using the cached version? So using an API will slow down my site, and not using it will speed it up? Are there any advantages to using the API? Or is it just that Google can "contact you directly if we find a problem with your site." Is AKA tracking you?

+6
source share
2 answers

Given http://html5boilerplate.com/ the guys do not use the API, I think it’s better not to do this. No one seems to know a good reason. And Google tracking your site is not a good reason (you are probably using Google Analytics!).

0
source

It says here the direct link is actually the fastest:

"The preferred way is to load libraries through standard tags (as in the script src =" https://ajax.googleapis.com/ajax/libs/jquery/1.4.2/jquery.min.js ">, which will lead to the fastest loads .

It says that several reasons for using Load are that you can get the latest version automatically or specify the language or automatically load (or not) load) css files, etc.

+1
source

Source: https://habr.com/ru/post/890553/


All Articles