Skip to content

Commit c609e71

Browse files
alan-agius4clydin
authored andcommitted
build: update to cssnano to version 5.0.0
Closes #19106
1 parent cc52e54 commit c609e71

File tree

4 files changed

+366
-64
lines changed

4 files changed

+366
-64
lines changed

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -138,7 +138,7 @@
138138
"core-js": "3.10.1",
139139
"critters": "0.0.10",
140140
"css-loader": "5.2.1",
141-
"cssnano": "4.1.11",
141+
"cssnano": "5.0.0",
142142
"debug": "^4.1.1",
143143
"enhanced-resolve": "5.7.0",
144144
"express": "4.17.1",

packages/angular_devkit/build_angular/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@
3131
"core-js": "3.10.1",
3232
"critters": "0.0.10",
3333
"css-loader": "5.2.1",
34-
"cssnano": "4.1.11",
34+
"cssnano": "5.0.0",
3535
"find-cache-dir": "3.3.1",
3636
"glob": "7.1.6",
3737
"https-proxy-agent": "5.0.0",

packages/angular_devkit/build_angular/src/webpack/plugins/optimize-css-webpack-plugin.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -87,9 +87,9 @@ export class OptimizeCssWebpackPlugin {
8787
};
8888

8989
const output = await new Promise<Result>((resolve, reject) => {
90-
// the last parameter is not in the typings
90+
// @types/cssnano are not up to date with version 5.
9191
// tslint:disable-next-line: no-any
92-
(cssNano.process as any)(content, postCssOptions, cssNanoOptions)
92+
(cssNano as any)(cssNanoOptions).process(content, postCssOptions)
9393
.then(resolve)
9494
.catch((err: Error) => reject(new Error(`${file} ${err.message}`)));
9595
});

0 commit comments

Comments
 (0)