Web Development Course:
This tutorial explains what formats of jQuery are available for download, and what their main differences are. You will also grasp how you may use CDN for that, or execute a jQuery UI CDN implementation. All the links you need will be provided.
jQuery Download: Main Tips
- jQuery is available in compressed and uncompressed formats.
- It can also be implemented via CDN.
Formats and Links
Before you download jQuery, you need to know this library is available in two formats: compressed and uncompressed. Both of them are available to download in the official jQuery web site.
The uncompressed format is preferable during development because of better readability. You can download it by clicking here.
Now, the compressed format saves bandwidth. Therefore, it is the better choice for improving your website's performance. You can download it by visiting this link. When using the compressed version, you may also want to download the jQuery sourcemap file in order to improve the debugger experience while developing.
Once the jQuery download is finished, you can move it to the directory of your website, be it on your computer or the file server.
When that is done, you can apply the library to your code using code like this in the
<head> element, using the
src attribute of the
<code> element to provide the file path to the file:
It is also possible to use jQuery without downloading. For that, you could use a content delivery network (CDN). You can also use it for additional jQuery libraries: for example, you might perform a jQuery UI CDN implementation.
There are various options - you might use jQuery CDN Google or another system has to offer. In this section, we will review a few of them.
For a CDN jQuery implementation, you have to use the same script as above, only instead of the file path, you need to enter the CDN link.
Here's a list of the various jQuery CDNs you can choose from:
This saves you the trouble of downloading, placing the file on the file server, and providing the path to it. On the flipside, when using CDN jQuery file cannot be edited.
Note: Due to the popularity of jQuery CDN Google and Microsoft options, users often have it cached. That leads to a faster loading time.
jQuery Download: Summary
- You can download jQuery in compressed or uncompressed format.
- However, jQuery download is not necessary: you can also implement it using CDN.