Skip to content

Commit

Permalink
fix(*): up css loader
Browse files Browse the repository at this point in the history
  • Loading branch information
stepancar committed Jan 27, 2020
1 parent 1013139 commit 32dec5e
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 5 deletions.
5 changes: 3 additions & 2 deletions configs/webpack.server.dev.js
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@ const config = {
.replace(/\\/g, '/'),
},
externals: [nodeExternals({
whitelist: [/^arui-feather/, /^arui-ft-private/, /^arui-private/, /^alfaform-core-ui/, /^#/]
whitelist: [/^arui-feather/, /^arui-ft-private/, /^arui-private/, /^alfaform-core-ui/, /^newclick-components/, /^#/]
})],
resolve: {
// This allows you to set a fallback for where Webpack should look for modules.
Expand Down Expand Up @@ -135,9 +135,10 @@ const config = {
test: cssModuleRegex,
use: [
{
loader: require.resolve('css-loader/locals'),
loader: require.resolve('css-loader'),
options: {
modules: true,
exportOnlyLocals: true,
localIdentName: getLocalIdentPattern({ isProduction: false })
},
},
Expand Down
5 changes: 3 additions & 2 deletions configs/webpack.server.prod.js
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ module.exports = applyOverrides(['webpack', 'webpackServer', 'webpackProd', 'web
.replace(/\\/g, '/'),
},
externals: [nodeExternals({
whitelist: [/^arui-feather/, /^arui-ft-private/, /^arui-private/, /^alfaform-core-ui/, /^#/]
whitelist: [/^arui-feather/, /^arui-ft-private/, /^arui-private/, /^alfaform-core-ui/, /^newclick-components/, /^#/]
})],
resolve: {
// This allows you to set a fallback for where Webpack should look for modules.
Expand Down Expand Up @@ -123,9 +123,10 @@ module.exports = applyOverrides(['webpack', 'webpackServer', 'webpackProd', 'web
test: cssModuleRegex,
use: [
{
loader: require.resolve('css-loader/locals'),
loader: require.resolve('css-loader'),
options: {
modules: true,
exportOnlyLocals: true,
localIdentName: getLocalIdentPattern({ isProduction: true })
},
},
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@
"chalk": "^2.3.1",
"compression-webpack-plugin": "2.0.0",
"copy-webpack-plugin": "4.6.0",
"css-loader": "1.0.1",
"css-loader": "2.1.1",
"enzyme": "3.7.0",
"enzyme-adapter-react-16": "1.7.0",
"enzyme-to-json": "3.3.4",
Expand Down

0 comments on commit 32dec5e

Please sign in to comment.