I basically want to add a filter:autojpg() to this and I have tried various combinations, but to no avail.
The PNG never converts to JPG. Any help would be appreciated. Thank you.
const cloudifyUrl = (uuid, width = 500, height = 500) => {
const imageRequest = JSON.stringify({
bucket: process.env.NEXT_PUBLIC_BUCKET_NAME,
key: uuid,
edits: {
resize: {
width,
height,
fit: 'cover',
},
},
});
return `${process.env.NEXT_PUBLIC_CLOUDFRONT_URL}/${btoa(imageRequest)}`;
};
I basically want to add a filter:autojpg() to this and I have tried various combinations, but to no avail.
The PNG never converts to JPG. Any help would be appreciated. Thank you.