From 8daf1e8f6af8c51a23678603c1757e8a84d1ba9a Mon Sep 17 00:00:00 2001 From: Santeri Hiltunen Date: Sat, 30 Nov 2024 16:24:04 +0200 Subject: [PATCH] Minify build output in production build --- template/build.mjs | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/template/build.mjs b/template/build.mjs index 7e2c1f0..22f4178 100644 --- a/template/build.mjs +++ b/template/build.mjs @@ -9,6 +9,8 @@ const { }, }); +const isProduction = !watch; + const options = { logLevel: "info", color: watch ? true : undefined, @@ -23,6 +25,8 @@ const options = { packages: "external", sourcemap: true, + bundle: false, + minify: isProduction, }; if (watch) {