Skip to content

Commit

Permalink
Fix ICSS syntax in stylesheets (facebook#10511)
Browse files Browse the repository at this point in the history
  • Loading branch information
thabemmz authored and wombleton committed Jun 1, 2021
1 parent e373935 commit 8bad6e7
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions packages/react-scripts/config/webpack.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -518,6 +518,9 @@ module.exports = function (webpackEnv) {
sourceMap: isEnvProduction
? shouldUseSourceMap
: isEnvDevelopment,
modules: {
compileType: 'icss',
},
}),
// Don't consider CSS imports dead code even if the
// containing package claims to have no side effects.
Expand All @@ -535,6 +538,7 @@ module.exports = function (webpackEnv) {
? shouldUseSourceMap
: isEnvDevelopment,
modules: {
compileType: 'module',
getLocalIdent: getCSSModuleLocalIdent,
},
}),
Expand All @@ -551,6 +555,9 @@ module.exports = function (webpackEnv) {
sourceMap: isEnvProduction
? shouldUseSourceMap
: isEnvDevelopment,
modules: {
compileType: 'icss',
},
},
'sass-loader'
),
Expand All @@ -571,6 +578,7 @@ module.exports = function (webpackEnv) {
? shouldUseSourceMap
: isEnvDevelopment,
modules: {
compileType: 'module',
getLocalIdent: getCSSModuleLocalIdent,
},
},
Expand Down

0 comments on commit 8bad6e7

Please sign in to comment.