Skip to content

Commit 60284b1

Browse files
authored
Update vite.config.js
1 parent c09ee0f commit 60284b1

1 file changed

Lines changed: 20 additions & 1 deletion

File tree

vite.config.js

Lines changed: 20 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,5 +32,24 @@ export default defineConfig({
3232
},
3333
optimizeDeps: {
3434
exclude: ['@ffmpeg/ffmpeg', '@ffmpeg/util']
35-
}
35+
},
36+
37+
// ===========================================
38+
// PRODUCTION BUILD CONFIGURATION
39+
// ===========================================
40+
build: {
41+
minify: 'esbuild', // Use esbuild for minification (faster than terser, already bundled with Vite)
42+
chunkSizeWarningLimit: 500, // Chunk size warning threshold (in KB)
43+
rollupOptions: {
44+
output: {
45+
manualChunks: { // Chunk splitting for better caching
46+
'vendor': ['vue', 'vue-router', 'pinia'],
47+
'ui': ['@vueuse/core', '@headlessui/vue', '@heroicons/vue'],
48+
},
49+
},
50+
},
51+
},
52+
define: {
53+
__VUE_PROD_DEVTOOLS__: false, // Disable Vue devtools in production
54+
},
3655
});

0 commit comments

Comments
 (0)