in website/plugins/image-ssr-plugin.js [30:51]
function getImageFilename(imageUrl) {
const hash = createHash("md5").update(imageUrl).digest("hex");
let ext = ".jpg";
try {
const parsedUrl = url.parse(imageUrl);
const pathname = parsedUrl.pathname || "";
const pathExt = path.extname(pathname);
if (pathExt) ext = pathExt;
if (
imageUrl.includes("img.shields.io") ||
imageUrl.includes("actions?query") ||
imageUrl.includes("github/actions/workflow")
) {
ext = ".svg";
}
} catch (e) {}
return `${hash}${ext}`;
}