JavaScript events for developers
Learn to use custom Javascript event listeners and triggers in Minimog theme
1. Page loaded
document.addEventListener('page:loaded', function() {
// Page has loaded and theme assets are ready
})2. Product successfully added to the Ajax cart
document.addEventListener('product-ajax:added', function(evt) {
console.log(evt.detail.product);
});3. Product could not be added to the Ajax cart
4. Cart updated
5. Quick view modal has been loaded
6. Variant selection changed
7. Collection page is refreshed
8. Trigger cart drawer to refresh
Last updated
