11ty / eleventy-img

Utility to perform build-time image transformations.

Home Page:https://www.11ty.dev/docs/plugins/image/

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Remove missing `sizes` attribute error when using `loading="lazy"`—swap to use `sizes="auto"` instead.

zachleat opened this issue · comments

Note that "auto" is already supported as a value for sizes in this plugin. This issue is specifically for the error message at:

let missingSizesErrorMessage = `Missing \`sizes\` attribute on eleventy-img shortcode from: ${originalSrc || attributes.src}`;

IMPORTANTLY sizes="auto" is not yet supported anywhere.

https://groups.google.com/a/chromium.org/g/blink-dev/c/OAsmCbjPJz0/m/jzuTJzs1AAAJ