Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
C
CFFP-HB
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Chao Sun
CFFP-HB
Commits
92a3595b
Commit
92a3595b
authored
Jul 24, 2025
by
zhangxingmin
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
push
parent
a9a2fc4f
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
5 additions
and
11 deletions
+5
-11
vite.config.js
+5
-11
No files found.
vite.config.js
View file @
92a3595b
...
...
@@ -48,19 +48,13 @@ export default defineConfig({
manifest
:
true
,
// 压缩代码
minify
:
'terser'
,
// 禁用哈希和合并
rollupOptions
:
{
output
:
{
// 自定义输出文件名
entryFileNames
:
'assets/[name].[hash].js'
,
chunkFileNames
:
'assets/[name].[hash].js'
,
assetFileNames
:
'assets/[name].[hash].[ext]'
,
// 手动分割代码
manualChunks
(
id
)
{
if
(
id
.
includes
(
'node_modules'
))
{
return
'vendor'
;
// 将第三方依赖打包到 vendor
}
}
entryFileNames
:
'[name].js'
,
chunkFileNames
:
'[name].js'
,
assetFileNames
:
'[name].[ext]'
,
// 保持原名
manualChunks
:
null
// 禁用依赖合并
}
}
},
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment