For some reason, some imageSizes doesn't get the correct format in prod, but in my local, payload creates the correct versions/formats
upload: {
staticURL: '/media',
staticDir: 'media',
imageSizes: [
{
name: 'hero',
width: 1440,
height: 810,
position: 'center',
},
{
name: 'thumbnail',
width: 576,
height: 432,
position: 'center',
},
{
name: 'square',
width: 800,
height: 800,
position: 'center',
},
],
mimeTypes: ['image/*'],
formatOptions: {
format: 'webp',
options: {
losselesss: true,
},
},
},
What versions of Payload are we looking at with these screenshots?
Im using payload 1.6.26
Im going to update to 1.6.27, I see that 1.6.26 wasn’t an oficial release.
well, I update, but now in local just the main file gets the webp format, the other sizes are created in png. :S
Found this in other post, I have to add the format for each size.
Yep, this works! 🙂
Star
Discord
online
Get help straight from the Payload team with an Enterprise License.