#Can payload save an image in multiple formats ?

4 messages · Page 1 of 1 (latest)

keen coral
#

I would like to have my images in jpg|webp|avif to support all browsers. I saw in the doc you could use sharp options to change the file format, but I didn't find anything about duping the file in other formats.

drowsy wraith
keen coral
#

So I should be able to save the file to others formats, but can the file still be linked to payload and get all the different types in the API response. I guess I would have to do some customisation in the afterRead hook ?

#

I guess overriding the API response also means the generated typescript schema would be wrong