How do I LazyLoad thumbnail images in Debut?

Hi SeaSpray,

Aibek is here from Growavelabs Agency.

Hope this message finds you well and safe.

First, you use lazysizes.js to defer loading of hidden images. The problem is that this library thinks the images are in the visible area of the web page. Therefore, the pictures are loaded immediately. But in reality they are hidden from the side. When users click on product thumbnails, the images are shown. The Pagespeed Insights algorithm can figure this out.

Alternatively, you can manually adjust the lazysizes. To do this, you need to lower the expand option. Below will be the code, try to paste immediately after connecting the js file lazysize.js to theme.liquid

window.lazySizesConfig = window.lazySizesConfig || {};
window.lazySizesConfig.expand = 10; //default 360-500 lazySizesConfig. expFactor = 1.5; //default: 1.7

If you have other questions, our developers can help you with that. Our agency is now offering free speed optimization for the Shopify Stores.

Feel free to fill out this form, and we can help you with your other requests. Link you can find here: https://mailchi.mp/f33da12dcb76/optimize-my-website