aboutsummaryrefslogtreecommitdiffstats
path: root/vite.config.js
diff options
context:
space:
mode:
authorGuilhem Moulin <guilhem@fripost.org>2026-05-25 18:45:31 +0200
committerGuilhem Moulin <guilhem@fripost.org>2026-05-25 19:05:35 +0200
commit55aec34a3568abf5eb2b8fbc854d295115aff8d1 (patch)
tree20be482742daf2fb9c210efeeec2f8a6e1c7e253 /vite.config.js
parent1620d839b9e8cf7688921d64b54dbef560787b3a (diff)
Upgrade vite to 8.0.x.
And adjust configuration accordingly, see https://vite.dev/guide/build#chunking-strategy
Diffstat (limited to 'vite.config.js')
-rw-r--r--vite.config.js25
1 files changed, 20 insertions, 5 deletions
diff --git a/vite.config.js b/vite.config.js
index 2e513f9..0af7e4d 100644
--- a/vite.config.js
+++ b/vite.config.js
@@ -8,11 +8,26 @@ export default {
assetsDir: "assets",
rollupOptions: {
output: {
- manualChunks: {
- ol: ['ol'],
- bootstrap: ['bootstrap'],
- proj4: ['proj4'],
- }
+ codeSplitting: {
+ groups: [
+ {
+ name: 'ol_source',
+ test: /node_modules[\\/]ol[\\/]source/,
+ },
+ {
+ name: 'ol',
+ test: /node_modules[\\/]ol/,
+ },
+ {
+ name: 'bootstrap',
+ test: /node_modules[\\/]bootstrap/,
+ },
+ {
+ name: 'proj4',
+ test: /node_modules[\\/]proj4/,
+ },
+ ],
+ },
}
}
},