support baidu map

This commit is contained in:
MaysWind
2023-06-17 13:40:34 +08:00
parent 530ef6b83e
commit 3bae6e749a
7 changed files with 230 additions and 89 deletions
+3 -1
View File
@@ -108,7 +108,9 @@ export default defineConfig(async () => {
chunkFileNames: 'js/[name]-[hash].js',
entryFileNames: 'js/[name]-[hash].js',
manualChunks: function (id) {
if (/[\\/]node_modules[\\/]/i.test(id)) {
if (/[\\/]node_modules[\\/]leaflet[\\/]/i.test(id)) {
return 'leaflet';
} else if (/[\\/]node_modules[\\/]/i.test(id)) {
return 'vendor';
}
}