Commit f9cb8ce authored and committed Mar 16, 2019
1 parent b1cf4cc commit f9cb8ce Copy full SHA for f9cb8ce
File tree 2 files changed +5
-5
lines changed
2 files changed +5
-5
lines changed Original file line number Diff line number Diff line change @@ -43,7 +43,7 @@ export default class InitGenerator extends Generator {
43
43
this . dependencies = [
44
44
"webpack" ,
45
45
"webpack-cli" ,
46
- "uglifyjs -webpack-plugin" ,
46
+ "terser -webpack-plugin" ,
47
47
"babel-plugin-syntax-dynamic-import" ,
48
48
] ;
49
49
this . configuration = {
@@ -430,12 +430,12 @@ export default class InitGenerator extends Generator {
430
430
public installPlugins ( ) {
431
431
if ( this . isProd ) {
432
432
this . dependencies = this . dependencies . filter (
433
- ( p : string ) => p !== "uglifyjs -webpack-plugin" ,
433
+ ( p : string ) => p !== "terser -webpack-plugin" ,
434
434
) ;
435
435
} else {
436
436
this . configuration . config . topScope . push (
437
437
tooltip . uglify ( ) ,
438
- "const UglifyJSPlugin = require('uglifyjs -webpack-plugin');" ,
438
+ "const TerserPlugin = require('terser -webpack-plugin');" ,
439
439
"\n" ,
440
440
) ;
441
441
}
Original file line number Diff line number Diff line change 3
3
* Callable function with the initial plugins
4
4
*
5
5
* @returns {Function } An function that returns an array
6
- * that consists of the uglify plugin
6
+ * that consists of terser-webpack- plugin
7
7
*/
8
8
9
9
export default function ( _ ?: void ) : string [ ] {
10
- return [ "new UglifyJSPlugin ()" ] ;
10
+ return [ "new TerserPlugin ()" ] ;
11
11
}
You can’t perform that action at this time.
0 commit comments