Fix Legacy CSS Modules on the Server (#8970)
CSS Modules run their loader on the server, so we need to patch both variants of the webpack configuration.
This commit is contained in:
parent
e9b2e25c44
commit
e2ca0ac0e8
1 changed files with 1 additions and 5 deletions
|
@ -922,11 +922,7 @@ export default async function getBaseWebpackConfig(
|
|||
}
|
||||
|
||||
// Patch `@zeit/next-sass` and `@zeit/next-less` compatibility
|
||||
if (
|
||||
!isServer &&
|
||||
webpackConfig.module &&
|
||||
Array.isArray(webpackConfig.module.rules)
|
||||
) {
|
||||
if (webpackConfig.module && Array.isArray(webpackConfig.module.rules)) {
|
||||
;[].forEach.call(webpackConfig.module.rules, function(
|
||||
rule: webpack.RuleSetRule
|
||||
) {
|
||||
|
|
Loading…
Reference in a new issue