How to disable WordPress 5.5+ built-in image delayed loading feature

WordPress 5.5 official versionReleased with built-in image delayed loading function, which is what we often call LazyLoad. But the built-in LazyLoad is implemented based on the browser’s built-in functions. For more technical details, please take a look at WordPress 5.5 ‘s built-in image delayed loading feature. What are the requirements for developers?

Not to mention the adaptability of WordPress 5.5 ‘s built-in delayed loading, just to say that many websites have delayed loading of images with built-in themes or through plug-ins. When multiple delayed loading functions are mixed, problems arise, and the pictures cannot be displayed properly for some reason.

So how to solve this problem? The recommended practice now is to disable the built-in image delayed loading feature of WordPress 5.5. This is also the most reliable and convenient method.

Simply add the following code to the functions.php of the theme you are using to disable it:

add_filter('wp_lazy_loading_enabled', '__return_false');

If you don’t understand twirling code, you can directly download and install the Disable Lazy Loading plug-in.

发表回复

您的邮箱地址不会被公开。 必填项已用 * 标注