payloadcms / payload-3.0-demo

The official demo for Payload 3.0
https://next-payload-3-0-test.vercel.app
433 stars 140 forks source link

I use image formatOptions in v3 but it doesn't work #194

Closed lctone closed 4 months ago

lctone commented 4 months ago

I use image formatOptions in v3 but it doesn't work

 upload: {
    staticDir: 'media',
    mimeTypes: ['image/*'],
    formatOptions: {
      format: 'webp',
      options: {
        quality: 80,
      },
    },
  },

Payload 3 beta 24

Thank you

denolfe commented 4 months ago

@lctone Can you confirm you are providing sharp to your config?

This will not work otherwise.

lctone commented 4 months ago

Thanks it was my mistake, forgot to configure sharp in version 3