Skip to content

Commit 3968923

Browse files
authoredDec 8, 2020
Revert "Update postcss packages" (#10216)
This reverts commit 580ed5d.
1 parent e039ad3 commit 3968923

File tree

2 files changed

+20
-23
lines changed

2 files changed

+20
-23
lines changed
 

‎packages/react-scripts/config/webpack.config.js

+17-19
Original file line numberDiff line numberDiff line change
@@ -125,25 +125,23 @@ module.exports = function (webpackEnv) {
125125
// package.json
126126
loader: require.resolve('postcss-loader'),
127127
options: {
128-
postcssOptions: {
129-
plugins: [
130-
require('postcss-flexbugs-fixes'),
131-
[
132-
require('postcss-preset-env'),
133-
{
134-
autoprefixer: {
135-
flexbox: 'no-2009',
136-
},
137-
stage: 3,
138-
},
139-
],
140-
// Adds PostCSS Normalize as the reset css with default options,
141-
// so that it honors browserslist config in package.json
142-
// which in turn let's users customize the target behavior as per their needs.
143-
postcssNormalize(),
144-
],
145-
},
146-
sourceMap: isEnvProduction && shouldUseSourceMap,
128+
// Necessary for external CSS imports to work
129+
// https://github.com/facebook/create-react-app/issues/2677
130+
ident: 'postcss',
Has a conversation. Original line has a conversation.
131+
plugins: () => [
132+
require('postcss-flexbugs-fixes'),
133+
require('postcss-preset-env')({
134+
autoprefixer: {
135+
flexbox: 'no-2009',
136+
},
137+
stage: 3,
138+
}),
139+
// Adds PostCSS Normalize as the reset css with default options,
140+
// so that it honors browserslist config in package.json
141+
// which in turn let's users customize the target behavior as per their needs.
142+
postcssNormalize(),
143+
],
144+
sourceMap: isEnvProduction ? shouldUseSourceMap : isEnvDevelopment,
147145
},
148146
},
149147
].filter(Boolean);

‎packages/react-scripts/package.json

+3-4
Original file line numberDiff line numberDiff line change
@@ -65,10 +65,9 @@
6565
"mini-css-extract-plugin": "0.11.3",
6666
"optimize-css-assets-webpack-plugin": "5.0.4",
6767
"pnp-webpack-plugin": "1.6.4",
68-
"postcss": "8.1.14",
Has a conversation. Original line has a conversation.
69-
"postcss-flexbugs-fixes": "5.0.2",
70-
"postcss-loader": "4.1.0",
71-
"postcss-normalize": "9.0.0",
Has a conversation. Original line has a conversation.
68+
"postcss-flexbugs-fixes": "4.2.1",
69+
"postcss-loader": "3.0.0",
70+
"postcss-normalize": "8.0.1",
7271
"postcss-preset-env": "6.7.0",
7372
"postcss-safe-parser": "5.0.2",
7473
"prompts": "2.4.0",

0 commit comments

Comments
 (0)
Please sign in to comment.