Continue using vendor chunk

This commit is contained in:
James Lyne 2022-06-18 21:12:54 +01:00
parent f4d489b474
commit 411d95d243

View File

@ -5,6 +5,7 @@ import { resolve } from 'path';
import vue from '@vitejs/plugin-vue';
import svgSpritePlugin from "vite-plugin-svg-sprite-component";
import analyze from 'rollup-plugin-analyzer';
import { splitVendorChunkPlugin } from 'vite'
export default defineConfig(({ mode }) => {
const env = loadEnv(mode, process.cwd())
@ -21,7 +22,7 @@ export default defineConfig(({ mode }) => {
);
return {
plugins: [vue(), analyze(), svgSpritePlugin({
plugins: [splitVendorChunkPlugin(), vue(), analyze(), svgSpritePlugin({
symbolId: (name) => `icon--${name}`,
removeAttrs: ['xmlns', 'width', 'height', 'version']
})],