File tree Expand file tree Collapse file tree 4 files changed +11
-11
lines changed Expand file tree Collapse file tree 4 files changed +11
-11
lines changed Original file line number Diff line number Diff line change 125125 "@types/rimraf" : " 0.0.28" ,
126126 "@types/semver" : " ^5.3.30" ,
127127 "@types/source-map" : " ^0.5.0" ,
128- "@types/webpack" : " ^2.2.4 " ,
128+ "@types/webpack" : " ^2.2.15 " ,
129129 "chai" : " ^3.5.0" ,
130130 "conventional-changelog" : " ^1.1.0" ,
131131 "dtsgenerator" : " ^0.9.1" ,
Original file line number Diff line number Diff line change @@ -82,8 +82,8 @@ export const getProdConfig = function (wco: WebpackConfigOptions) {
8282 return {
8383 entry : entryPoints ,
8484 plugins : [
85- new webpack . DefinePlugin ( {
86- 'process.env. NODE_ENV' : JSON . stringify ( 'production' )
85+ new webpack . EnvironmentPlugin ( {
86+ 'NODE_ENV' : 'production'
8787 } ) ,
8888 new ( < any > webpack ) . HashedModuleIdsPlugin ( ) ,
8989 new webpack . optimize . UglifyJsPlugin ( < any > {
Original file line number Diff line number Diff line change @@ -126,8 +126,8 @@ class JsonWebpackSerializer {
126126 } ) ;
127127 }
128128
129- _definePlugin ( plugin : any ) {
130- return plugin . definitions ;
129+ _environmentPlugin ( plugin : any ) {
130+ return plugin . defaultValues ;
131131 }
132132
133133 private _pluginsReplacer ( plugins : any [ ] ) {
@@ -169,9 +169,9 @@ class JsonWebpackSerializer {
169169 args = this . _htmlWebpackPlugin ( plugin ) ;
170170 this . variableImports [ 'html-webpack-plugin' ] = 'HtmlWebpackPlugin' ;
171171 break ;
172- case webpack . DefinePlugin :
173- args = this . _definePlugin ( plugin ) ;
174- this . _addImport ( 'webpack' , 'DefinePlugin ' ) ;
172+ case webpack . EnvironmentPlugin :
173+ args = this . _environmentPlugin ( plugin ) ;
174+ this . _addImport ( 'webpack' , 'EnvironmentPlugin ' ) ;
175175 break ;
176176
177177 default :
Original file line number Diff line number Diff line change 138138 dependencies :
139139 " @types/source-map" " *"
140140
141- " @types/webpack@^2.2.4 " :
142- version "2.2.12 "
143- resolved "https://registry.yarnpkg.com/@types/webpack/-/webpack-2.2.12 .tgz#5e2ab82b5b43cfadcb308d3210c082cf67fd9893 "
141+ " @types/webpack@^2.2.15 " :
142+ version "2.2.15 "
143+ resolved "https://registry.yarnpkg.com/@types/webpack/-/webpack-2.2.15 .tgz#4ad7e9b7a51cae736a1dc783f203610c884789ff "
144144 dependencies :
145145 " @types/node" " *"
146146 " @types/tapable" " *"
You can’t perform that action at this time.
0 commit comments