I have built a new section for my theme that uses blocks to create slides in a slideshow. I need to be able make the appropriate slide active when it’s being edited through the customizer. From what I’ve been able to find online, it requires tapping into Shopify’s “shopify:block:select” event so I wrote a very simple function for testing.
document.addEventListener('shopify:block:select', function(event) {
console.log(event);
});
I’ve put that code in my theme’s js file as well as inline in my new section. I’ve confirmed the code is there but no matter what I do, I cannot get that event to fire. Anyone know what I’m doing wrong?