Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
V
VueElementTemplate
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
JIRA
JIRA
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
黄瑜
VueElementTemplate
Commits
61095a9f
Commit
61095a9f
authored
Nov 09, 2017
by
Pan
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
refactor:refine webpack.prod.conf.js
parent
61deec54
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
4 additions
and
6 deletions
+4
-6
.babelrc
.babelrc
+1
-4
webpack.prod.conf.js
build/webpack.prod.conf.js
+3
-2
No files found.
.babelrc
View file @
61095a9f
{
"presets": [
["env", {
"modules": false,
"targets": {
"browsers": ["> 1%", "last 2 versions", "not ie <= 8"]
}
"modules": false
}],
"stage-2"
],
...
...
build/webpack.prod.conf.js
View file @
61095a9f
...
...
@@ -27,11 +27,10 @@ var webpackConfig = merge(baseWebpackConfig, {
output
:
{
path
:
config
.
build
.
assetsRoot
,
filename
:
utils
.
assetsPath
(
'js/[name].[chunkhash].js'
),
chunkFilename
:
utils
.
assetsPath
(
'js/[
id
].[chunkhash].js'
),
chunkFilename
:
utils
.
assetsPath
(
'js/[
name
].[chunkhash].js'
),
publicPath
:
config
.
build
.
assetsPublicPath
},
plugins
:
[
new
webpack
.
optimize
.
ModuleConcatenationPlugin
(),
// http://vuejs.github.io/vue-loader/en/workflow/production.html
new
webpack
.
DefinePlugin
({
'process.env'
:
env
,
...
...
@@ -77,6 +76,8 @@ var webpackConfig = merge(baseWebpackConfig, {
}),
// cache Module Identifiers
new
webpack
.
HashedModuleIdsPlugin
(),
// enable scope hoisting
new
webpack
.
optimize
.
ModuleConcatenationPlugin
(),
// split vendor js into its own file
new
webpack
.
optimize
.
CommonsChunkPlugin
({
name
:
'vendor'
,
...
...
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