Skip to content

Commit d62b3d4

Browse files
committed
perf: 优化打包
1 parent 5d0e317 commit d62b3d4

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

vite.config.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -72,7 +72,7 @@ export default defineConfig(({ mode }: ConfigEnv): UserConfig => {
7272
output: {
7373
chunkFileNames: 'js/[name]-[hash].js', // chunk包输出的文件夹名称
7474
entryFileNames: 'js/[name]-[hash].js', // 入口文件输出的文件夹名称
75-
assetFileNames: '[ext]/[name]-[hash].[ext]', // 静态文件输出的文件夹名称
75+
assetFileNames: 'assets/[ext]/[name]-[hash].[ext]', // 静态文件输出的文件夹名称
7676
// 手动分包,将第三方库拆分到单独的chunk包中(注意这些包名必须存在,否则打包会报错)
7777
manualChunks: {
7878
'vendor-react': ['react', 'react-dom', 'react-router'],

0 commit comments

Comments
 (0)