Replies: 0
Hey folks, I’m the dev for the EWWW Image Optimizer, and we’ve had a lot of folks request integration with your product variations and our JS-based WebP rewriter.
However, I’m running into a bit of a road block with the image URLs that are in a JSON object attached via the data-product_variations attribute on form.variations_form.
Short of trying to un-escape and then decode the JSON with PHP (after grabbing it with a regex…), it would be much easier to parse the original array before it gets JSON encoded (in templates/single-product/add-to-cart/variable.php). I couldn’t find any suitable filters already in the code, so I’m wondering if it would be possible to have one added in a future release?
Thanks for your time!