Files
klz-cables.com/.pnpm-store/v10/files/44/ed84f9a0dbc72268290164faa6fa87f2da11b0b1466ca8e78fcc85802c78a399ab115ecbae52b3dd112d09dce413f83703e4099dc8e16f338d32495249c951
Marc Mintel 5397309103
Some checks failed
Build & Deploy / 🔍 Prepare (push) Successful in 20s
Build & Deploy / 🧪 QA (push) Failing after 34s
Build & Deploy / 🏗️ Build (push) Has started running
Build & Deploy / 🚀 Deploy (push) Has been cancelled
Build & Deploy / 🧪 Smoke Test (push) Has been cancelled
Build & Deploy / ⚡ Lighthouse (push) Has been cancelled
Build & Deploy / 🔔 Notify (push) Has been cancelled
fix(products): fix breadcrumbs and product filtering (backport from main)
2026-02-24 16:04:21 +01:00

40 lines
1.2 KiB
Plaintext

/*
MIT License http://www.opensource.org/licenses/mit-license.php
Author Sean Larkin @thelarkinn
*/
"use strict";
const { formatSize } = require("../SizeFormatHelpers");
const WebpackError = require("../WebpackError");
/** @typedef {import("./SizeLimitsPlugin").EntrypointDetails} EntrypointDetails */
class EntrypointsOverSizeLimitWarning extends WebpackError {
/**
* @param {EntrypointDetails[]} entrypoints the entrypoints
* @param {number} entrypointLimit the size limit
*/
constructor(entrypoints, entrypointLimit) {
const entrypointList = entrypoints
.map(
(entrypoint) =>
`\n ${entrypoint.name} (${formatSize(
entrypoint.size
)})\n${entrypoint.files.map((asset) => ` ${asset}`).join("\n")}`
)
.join("");
super(`entrypoint size limit: The following entrypoint(s) combined asset size exceeds the recommended limit (${formatSize(
entrypointLimit
)}). This can impact web performance.
Entrypoints:${entrypointList}\n`);
/** @type {string} */
this.name = "EntrypointsOverSizeLimitWarning";
this.entrypoints = entrypoints;
}
}
/** @type {typeof EntrypointsOverSizeLimitWarning} */
module.exports = EntrypointsOverSizeLimitWarning;