by iambavith · 1y ago · 0 comments
Also, because you're using CompressorJS's default settings, you should know that PNG files > 5 MB are converted to JPG (https://github.com/fengyuanchen/compressorjs?tab=readme-ov-f...). Your site, however, keeps the .png file name ending for the converted image, again falsely suggesting lossless compression.
I presume this is an oversight; changing CompressorJS's quality setting from its default of 0.8 to 0.75 results in the exact same output as ImgFiber.
Full settings dump:
{
"strict": true,
"checkOrientation": true,
"retainExif": false,
"maxWidth": null,
"maxHeight": null,
"minWidth": 0,
"minHeight": 0,
"resize": "none",
"quality": 0.75,
"mimeType": "auto",
"convertTypes": [
"image/png"
],
"convertSize": 5000000,
"beforeDraw": null,
"drew": null
}