Discuss and resolve questions on Liquid, JavaScript, themes, sales channels, and site speed enhancements.
Hi there.
I am preloading the product tag for speed improvement and I am using <picture> tag to load the product images.
The problem i have is that the preloaded image has a different version than the product image on the page:
preloaded image: _508x508.jpg?v=1612807210
image on the page: _508x508.jpg?v=1612807211
The code i am using for preloading is this:
<link rel="preload" as="image" href="{{ product.featured_image.src | img_url:'400x400' }}" media="(max-width: 767.98px)">
And the code inside product.liquid is this:
<picture>
<source media="(max-width: 767.98px)" srcset="{{ product.featured_image.src | img_url:'400x400' }}">
<img src="(min-width: 300px)" srcset="{{ product.featured_image.src | img_url:'400x400' }}"
alt="{{ image.alt | escape }}">
</picture>
Can anyone explain why this happens?
Hello @Kalipsso ,
Hey Community 👋 Did you know that March 15th is National Everything You Think Is W...
By JasonH Apr 1, 2025Discover how to increase the efficiency of commerce operations with Shopify Academy's l...
By Jacqui Mar 26, 2025Shopify and our financial partners regularly review and update verification requiremen...
By Jacqui Mar 14, 2025