Is there a way in JS/jQuery to "block" the loading of certain images in the DOM, up until a certain event occurs?
In my case, I have a page of products (WooCommerce Shop page) where clicking a product opens a modal window containing the image gallery of that particular product. But instead of loading galleries of all products on page load (too slow) I'd like to bind the loading of the image gallery to the opening of the modal window.
I'm guessing it's not really possible but perhaps there's some trick that comes close?