diff --git a/eslint.config.js b/eslint.config.js index 61434bb5cef..41fb4663836 100644 --- a/eslint.config.js +++ b/eslint.config.js @@ -44,4 +44,15 @@ export default [ ], }, }, + { + files: ["src/scripts/**/*.{js,ts}"], + rules: { + "no-console": [ + "error", + { + allow: ["warn", "error"], + }, + ], + }, + }, ]; diff --git a/src/scripts/explain-code.ts b/src/scripts/explain-code.ts index 26a0ace5fe8..110ddf8765a 100644 --- a/src/scripts/explain-code.ts +++ b/src/scripts/explain-code.ts @@ -10,7 +10,6 @@ function getCodeBlockPosition(button: HTMLElement): number { while (currentBlock) { if (currentBlock.tagName === "PRE") { currentBlock = currentBlock.querySelector(codeSelector); - console.log(currentBlock); break; } currentBlock = currentBlock.previousElementSibling;