note re if you're doing multiple widths

This commit is contained in:
2026-02-20 08:01:41 -08:00
parent 3848af101b
commit 6203735ff8

View File

@ -92,7 +92,12 @@ export default async function(eleventyConfig) {
decoding: "async", decoding: "async",
}, },
}, },
filenameFormat: function (id, src, width, format, options) { filenameFormat: function (hash, src, width, format, options) {
// If you're building multiple widths
// const extension = path.extname(src);
// const name = path.basename(src, extension);
// return `${name}-${width}.${extension}`;
return path.basename(src); return path.basename(src);
}, },
}); });