chore: disable avif transcoding (#495)

The trade-off is not worth it, it isn't *that* good for screenshots and
it uses too much memory and increases build time by a order of magnitude

Reviewed-on: https://codeberg.org/Codeberg/Documentation/pulls/495
Co-authored-by: Gusted <postmaster@gusted.xyz>
Co-committed-by: Gusted <postmaster@gusted.xyz>
This commit is contained in:
Gusted 2024-11-30 13:13:22 +00:00 committed by Gusted
parent b93f3ec429
commit f169569807
2 changed files with 2 additions and 2 deletions

View file

@ -17,4 +17,4 @@ On the technical side, screenshots should ideally be created in PNG and WebP or
Please put screenshots under `content/images/[section]/[article]/...` where `[section]` and `[article]` are the kebab-cased names of the section or your article, respectively.
Codeberg Documentation encodes images to Avif, WebP and JPEG format on build time, in order to increase page loading speed and reduce traffic.
Codeberg Documentation encodes images to WebP, JPEG and PNG format on build time, in order to increase page loading speed and reduce traffic.

View file

@ -14,7 +14,7 @@ export default function (eleventyConfig) {
eleventyConfig.addPlugin(syntaxHighlightingPlugin);
eleventyConfig.addPlugin(eleventyImageTransformPlugin, {
extensions: 'html',
formats: ['avif', 'webp', 'jpeg'],
formats: ['webp', 'jpeg', 'png'],
widths: ['auto'],
defaultAttributes: {
loading: 'lazy',