From 7a818732852c271723d362a157a2ed8f49efddfa Mon Sep 17 00:00:00 2001 From: Carlos Santos <4a.santos@gmail.com> Date: Tue, 20 May 2025 11:37:10 +0200 Subject: [PATCH] webcomponent: enhance console log removal configuration in terser for production --- frontend/webcomponent/rollup.config.js | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/frontend/webcomponent/rollup.config.js b/frontend/webcomponent/rollup.config.js index 3263566..a92a48d 100644 --- a/frontend/webcomponent/rollup.config.js +++ b/frontend/webcomponent/rollup.config.js @@ -39,7 +39,11 @@ export default { terser({ ecma: 2020, // Use modern features when possible compress: { - drop_console: production, // Remove console.logs in production + drop_console: { + log: production, // Remove console.logs in production + warn: true, + error: true + }, drop_debugger: production, pure_getters: true, unsafe: true,