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

AVIF support #13

Closed multipliedtwice closed 1 year ago

multipliedtwice commented 1 year ago

Could you please add AVIF?

const allowType = ['JPEG', 'PNG', 'GIF', 'SVG', 'TIFF', 'ICO', 'DVU', 'JPG', 'WEBP'];

stafyniaksacha commented 1 year ago

Hello @multipliedtwice ! It's released in v1.3.0!

zirho commented 9 months ago

converting image * to AVIF works since this change. However, converting from AVIF does not

https://github.com/ram-you/strapi-plugin-local-image-sharp/blob/main/src/middleware.js#L148 this line raises an error

[2023-12-10 15:43:55.962] debug: IPX Error (unsupported file type: undefined (file: undefined))

I guess this is due to the dependency to IPX package. The latest is 2.x.x and this package is on 0.9.x

I hope someone can catch up on this. I will try to hop on it when I get some bandwidth.