Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Q
qsh-wc
Project
Project
Details
Activity
Releases
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
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
honghuiliu
qsh-wc
Commits
11b73c69
Commit
11b73c69
authored
Sep 06, 2022
by
mahui
Browse files
Options
Browse Files
Download
Plain Diff
Merge remote-tracking branch 'origin/master'
parents
34654f6f
dac2f8f2
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
43 additions
and
28 deletions
+43
-28
.gitignore
.gitignore
+30
-9
vite.config.js
web/vite.config.js
+13
-19
No files found.
.gitignore
View file @
11b73c69
/.idea
/*.exe
/*.gz
/cache
*.tmp
/main
/vendor
/.vscode
*.tar
.idea/
/web/node_modules
/web/dist
.DS_Store
# local env files
.env.local
.env.*.local
# Log files
npm-debug.log*
yarn-debug.log*
yarn-error.log*
# Editor directories and files
.idea
.vscode
*.suo
*.ntvs*
*.njsproj
*.sln
*.sw?
/server/log/
/server/gva
/server/latest_log
/server/*.exe
*.iml
web/vite.config.js
View file @
11b73c69
...
...
@@ -8,9 +8,9 @@ import * as fs from 'fs'
import
vuePlugin
from
'@vitejs/plugin-vue'
// @see https://cn.vitejs.dev/config/
export
default
({
command
,
mode
})
=>
{
command
,
mode
})
=>
{
const
NODE_ENV
=
process
.
env
.
NODE_ENV
||
'development'
const
envFiles
=
[
`.env.
${
NODE_ENV
}
`
...
...
@@ -26,18 +26,13 @@ export default ({
const
timestamp
=
Date
.
parse
(
new
Date
())
const
rollupOptions
=
{
output
:
{
entryFileNames
:
`gva/gin-vue-admin-[name].
${
timestamp
}
.js`
,
chunkFileNames
:
`js/gin-vue-admin-[name].
${
timestamp
}
.js`
,
assetFileNames
:
`assets/gin-vue-admin-[name].
${
timestamp
}
.[ext]`
,
manualChunks
(
id
)
{
if
(
id
.
includes
(
'node_modules'
))
{
return
id
.
toString
().
split
(
'node_modules/'
)[
1
].
split
(
'/'
)[
0
].
toString
();
}
}
}
}
// const rollupOptions = {
// output: {
// entryFileNames: `gva/gin-vue-admin-[name].${timestamp}.js`,
// chunkFileNames: `js/gin-vue-admin-[name].${timestamp}.js`,
// assetFileNames: `assets/gin-vue-admin-[name].${timestamp}.[ext]`
// }
// }
const
optimizeDeps
=
{}
...
...
@@ -72,13 +67,12 @@ export default ({
},
},
build
:
{
target
:
'es201
5
'
,
target
:
'es201
7
'
,
minify
:
'terser'
,
// 是否进行压缩,boolean | 'terser' | 'esbuild',默认使用terser
manifest
:
false
,
// 是否产出manifest.json
sourcemap
:
false
,
// 是否产出sourcemap.json
outDir
:
'dist'
,
// 产出目录
chunkSizeWarningLimit
:
1500
,
rollupOptions
,
// rollupOptions,
},
esbuild
,
optimizeDeps
,
...
...
@@ -96,4 +90,4 @@ export default ({
}
},
}
}
}
\ No newline at end of file
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