Skip to content

Commit 92a11de

Browse files
committed
fix(@angular/cli): ensure purify is before uglify
1 parent 37bf9e9 commit 92a11de

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

packages/@angular/cli/models/webpack-configs/production.ts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -136,6 +136,8 @@ export function getProdConfig(wco: WebpackConfigOptions) {
136136
}),
137137
new webpack.HashedModuleIdsPlugin(),
138138
new webpack.optimize.ModuleConcatenationPlugin(),
139+
...extraPlugins,
140+
// Uglify should be the last plugin as PurifyPlugin needs to be before it.
139141
new UglifyJSPlugin({
140142
sourceMap: buildOptions.sourcemaps,
141143
uglifyOptions: {
@@ -150,7 +152,6 @@ export function getProdConfig(wco: WebpackConfigOptions) {
150152
},
151153
}
152154
}),
153-
...extraPlugins
154155
]
155156
};
156157
}

0 commit comments

Comments
 (0)