strapi-community / strapi-plugin-local-image-sharp

Dynamically resize, format and optimize images based on url modifiers.
https://strapi-community.github.io/strapi-plugin-local-image-sharp/
65 stars 17 forks source link

Question: can it transform the image to webp on image upload? #8

Open Antoine-lb opened 2 years ago

Antoine-lb commented 2 years ago

Hello,

I was wandering if this plugin-in could be used to turn all my uploaded images to webp on upload instead of when it's retrieved.

Thanks!

esiao commented 1 year ago

I have the same question, as I'm using Digital Ocean Spaces to store my files it would be beneficial for the images to be saved there versus the local server.

Krislunde commented 1 year ago

This other Strapi plugin uses Sharp to do what you ask, but doesn't have the ability to do things on the fly on http requests like local image sharp does. It'll create webps on upload -if you specify it in the settings. If you decide you want webp after all your images have been uploaded you will have to upload them again to regenerate:

https://market.strapi.io/plugins/strapi-plugin-responsive-image