(error)
| 1309 | */ |
| 1310 | const joinError = |
| 1311 | (error) => |
| 1312 | /** |
| 1313 | * Handles the callback logic for this hook. |
| 1314 | * @param {Item[]} items items |
| 1315 | * @param {StatsPrinterContextWithExtra} ctx context |
| 1316 | * @returns {string} result |
| 1317 | */ |
| 1318 | (items, { red, yellow }) => |
| 1319 | `${error ? red("ERROR") : yellow("WARNING")} in ${joinExplicitNewLine( |
| 1320 | items, |
| 1321 | "" |
| 1322 | )}`; |
| 1323 | |
| 1324 | /** @typedef {{ element: string, content: string | undefined }} Item */ |
| 1325 | /** @typedef {(items: Item[], context: StatsPrinterContextWithExtra & Required<KnownStatsPrinterContext>) => string} SimpleElementJoiner */ |
no test coverage detected