Discuss and resolve questions on Liquid, JavaScript, themes, sales channels, and site speed enhancements.
Hello,
I'm encountering a caching issue with the Storefront API. Specifically, when a product is updated in the Shopify Admin, the Storefront API continues to serve a cached, outdated version of the product for several seconds. This seems inconsistent, as the Admin API correctly clears the cache upon product updates.
For instance, when our Next.js frontend utilizes a Shopify webhook to revalidate a product page cache, it fetches product data from the Storefront API. Unfortunately, this data is often outdated, leading to incorrect page generation for our cache.
Could you clarify whether the Storefront API cache is supposed to clear automatically for that product, when a product is updated in the Shopify Admin, and if not, suggest a solution?
Currently we wait to revalidate the product cache after 10 seconds, but it's still inconsistent.
Thank you.
Hey Community! As the holiday season unfolds, we want to extend heartfelt thanks to a...
By JasonH Dec 6, 2024Dropshipping, a high-growth, $226 billion-dollar industry, remains a highly dynamic bus...
By JasonH Nov 27, 2024Hey Community! It’s time to share some appreciation and celebrate what we have accomplis...
By JasonH Nov 14, 2024