How To Properly Add jQuery Scripts To WordPress

WordPress has been in our lives for over 16 years, yet the method of adding scripts to themes and plugins still remains a mystery for many developers. In this article we finally put the confusion to rest. Since it’s one of the most commonly used Javascript libraries, today we’re discussing how to add simple jQuery scripts to your WordPress themes …

WordPress 5.6 Will Ship With Another Major jQuery Change

WordPress 5.6 will ship with the latest jQuery library next month. This is a major update that all plugin and theme developers should begin testing against. Last week, Marius Jensen announced the change on the Make Core blog. The following jQuery-related libraries are expected to ship in the update (WordPress Trac ticket): jQuery 3.5.1 jQuery Migrate 3.3.2 jQuery UI 1.12.1 …

How to Defer Offscreen Images in WordPress With Lazy Loading

One of Google PageSpeed Insights performance suggestions is to defer offscreen images in WordPress with lazy loading. Lazy loading images in WordPress lowers the initial load time and page payload, without sacrificing content. Lazy loading improves your visitor’s experience, by serving only what your visitors need when they need it. It’s way more efficient than the load-all-the-images-just-in-case approach that results …

Is Replacing Default WordPress Scripts Like jQuery a Good Idea? (and How to Do It)

WordPress comes with a whole bunch of default scripts out-of-the-box that you can take advantage of to power your themes and plugins. jQuery is one commonly used script, as is TinyMCE. But what if you want to replace a built-in script with your own? We recently looked at how to add jQuery scripts properly to your install. WordPress uses the same mechanism …