From 4342239dab14f9eba3a3985db9eb3d0340c7d1c2 Mon Sep 17 00:00:00 2001 From: Trevor Manz Date: Thu, 10 Jun 2021 13:03:47 -0400 Subject: [PATCH] optimize production build --- snowpack.config.js | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/snowpack.config.js b/snowpack.config.js index 8ae2528a..c76ef8cb 100644 --- a/snowpack.config.js +++ b/snowpack.config.js @@ -1,9 +1,9 @@ -/** @type {import("snowpack").SnowpackUserConfig } */ const pkg = require('./package.json'); // pkg version avaiable in app via import.meta.env.SNOWPACK_PUBLIC_PACKAGE_VERSION process.env.SNOWPACK_PUBLIC_PACKAGE_VERSION = pkg.version; +/** @type {import("snowpack").SnowpackUserConfig} */ module.exports = { mount: { public: '/', @@ -26,6 +26,11 @@ module.exports = { out: 'out', baseUrl: process.env.VIZARR_PREFIX || './', }, + optimize: { + bundle: true, + minify: true, + splitting: true, + }, alias: { /* ... */ },