Use cdnjs WordPress Plugin To Offload Your Scripts

elegant themes affiliate

Cdnjs WordPress plugin allows you to offload your scripts to CloudFlare network and thus helps to increase your blog’s speed. WordPress by default has inbuilt support for offloading which means that instead of serving static content from your own server they are served from CDN. Now as CDN consist of multiple high-speed networks all across the globe so it directly improves your website performance and helps to reduce the load on your server.

If you are the owner of a blog or a magazine website which receives tens of thousands of visitors on a daily basis then you might not like your site to go down even for one minute. Even a one minute of downtime means decreasing conversion rate and higher bounce rate. So it’s always better to use all possible options which can help to improve your website’s performance.

cdnjs wordpress plugin

Cdnjs is an open community-based project which hosts hundreds of different JavaScript, images, SWF and stylesheets related to different open source projects.Since it’s an open source project so everyone has the ability to host their own files but first your files need to gather a good amount of up votes.

Cdnjs is powered by cloudflare and is currently being used by millions of worldwide users. It allows you to host and use hosted scripts on your own website through their powerful, managed, high-speed network. One another similar service is jsDeliver which is powered by both cloudflare and maxcdn. Cloudflare is a popular free CDN service provider which is known best for their high standard security which the offer for free to their users.

Why Should You Use cdnjs WordPress Plugin

It’s not easy for everyone to create and modify PHP files. If you would be a website developer then it would be a task of fewer than two minutes for you to offload scrips from your website to any other CDN. But the problem is not everyone is a developer and not everyone needs to understand PHP. And that’s the reason why plugins and addons are the developed.

The same goes with CDN’s WordPress plugin. It gives you the freedom to search and include any JavaScript or CSS file hosted on their library to your blog with just a click of a button.

Below I have listed out few of its other important features which makes it really useful plugin.

  • Inbuilt capability to search cdnjs library.
  • Has support for both HTTPs and HTTP.
  • Gives you the freedom to enable or disable particular library for a particular page or for the complete site.
  • Provides you with the option to Load the scripts either in header section or in the footer section.
  • Gives you the option to select additional assets like minified files.
  • Easily integrates with existing WordPress theme or plugin.

And most importantly allows you to use CloudFlare’s high-speed network for free of cost.

How To Install & Use cdnjs Plugin

In order to use it, you will have to first install. In order to complete the installation, you will have to first visit your Administration panel. From your WordPress admin panel you will have to visit your plugin’s page and from there you can search for WP cdnjs. Once you find it in the search results just click on the install link and on the next page click on the activate button. And it will be installed successfully.

In most of the cases, you don’t need to use this add-on especially if you are a writer or a simple blogger. But if your theme uses lots of scripts like bootstrap, fit vids, font awesome then it’s meant for you.

In order to use it, you will have two first visit its options page. On this page, you will find a search bar which allows you to search through their indexed files for your required files.

If they are found then you can click on it and they will be automatically added to the list. You will also be provided with second assets which provide you with an option to use the minified version of the requested file. The minified version will always be of a smaller size as compared to the original because in minified version the whitespaces and comments are removed. This, in turn, makes the code not readable by humans but also reduces its size.

If you search for more than one file then you are provided with a drag-and-drop interface which allows you to order the files in the way you want to load them. So the first one in the list will be loaded first and the last one in the list will be loaded at the last.

So overall WP cdnjs is a great plugin which can help to improve your website performance without any hassle.

Leave a Comment