How to change the srcset of woocommerce product thumbnails

Question

I am using the add_filter function to change the product image src and srcset. Unfortunately, only the src is changed but the srcset set remains the same. Which filter can I use to modify the srcset of woocommerce product images?

Here’s the code:

add_filter('wc_get_attachment_image_attributes',array(<Class>,<Function>),999);
0
Lucky Chingi 4 months 0 Answers 9 views 0

Leave an answer