The jQuery is the most popular JavaScript library that is used to develop useful & awesome functionalities, effects and widgets for you website/app.
In order to get started with jQuery, you have to include this library in your website. There are several ways to install jQuery in your website.
1.Download jQuery js file and include it into your website’s head tags. An example below:
<head> <script src="js/jquery.min.js"></script> </head>
Tip: Create a folder with the name “js” and place the downloaded jquery file into it.
Adding jQuery by Content Delivery Network
If you don’t want to download & host jQuery on your own server/local computer, you can also add it by a CDN’s single link.
There are various content delivery networks on the web that offers jQuery and other libraries, the following are some popular CDN to include jQuery into your projects.
Google CDN:
<script src="https://ajax.googleapis.com/ajax/libs/jquery/3.3.1/jquery.min.js"></script>
Microsoft CDN:
<script src="https://ajax.aspnetcdn.com/ajax/jQuery/jquery-3.3.1.min.js"></script>
Cloudflare CDN:
<script src="https://cdnjs.cloudflare.com/ajax/libs/jquery/3.3.1/jquery.min.js"></script>
Tip: Copy only one link from the above mentioned CDN and paste it into your website’s head tag.