
Step 1: Add the below line of code in “Theme.liquid”
Add the following code:
<script src="https://cdn.jsdelivr.net/npm/canvas-confetti@1.6.0/dist/confetti.browser.min.js"></script>
Step 2: Add the below code in snippets “buy-buttons.liquid”file
Just before the following code </product-form>, add the below code:
<script>
document.addEventListener('DOMContentLoaded', function() {
const addToCartButton = document.querySelector('#ProductSubmitButton-{{ section_id }}');
if (addToCartButton) {
addToCartButton.addEventListener('click', function() {
confetti({
particleCount: 200, // Number of confetti particles
spread: 100, // Spread of the confetti
origin: { y: 0.8, x: 0.8 } // Confetti origin point, 0 is the top, 1 is the bottom
});
});
}
});
</script>
![How I Find Google Maps Leads in Minutes with Claude Desktop + BrowserAct [No Code]](/_astro/How%20I%20Find%20Google%20Maps%20Leads%20in%20Minutes%20with%20Claude%20Desktop%20_%20BrowserAct%20_No%20Code_.DiiNHRev_3N5M4.webp)
%20The%203%20Biggest%20Updates%20for%20Store%20Owners.CY244rkl_1XVeRg.webp)
![How To Connect Google Search Console with Shopify - [2027]](/_astro/How%20To%20Connect%20Google%20Search%20Console%20with%20Shopify%20-%20_2027_%20(Step-by-Step).DoPyjVIZ_Z20rrU7.webp)


