mirror of
https://github.com/vercel/next.js.git
synced 2026-09-20 02:25:18 +08:00
deed868499
In a previous PR, `mozjpeg` was set to true which might be the reason output jpeg spikes cpu. - https://github.com/vercel/next.js/pull/65846 I made a benchmark and found that disabling MozJPEG saved 72% CPU, with average outputs 31% larger. - https://github.com/lovell/sharp/issues/4603 So this PR adds a new experimental flag to enable (or rather disable) mozjpeg and try with real workloads. This is useful becaues in many cases, cpu is more costly than bandwidth since most CDNs provide [near unlimited bandwidth](https://vercel.com/blog/introducing-flat-rate-cdn).