Skip to content

Commit

Permalink
Use named module IDs to fix prod build
Browse files Browse the repository at this point in the history
Unfortunately, the hashed module IDs were sometime not the same between the client and server build.
  • Loading branch information
unstubbable committed Mar 3, 2023
1 parent aaa12b1 commit 24caf7b
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions webpack.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ const serverConfig = {
},
optimization: dev
? undefined
: {concatenateModules: false, usedExports: false, moduleIds: `hashed`},
: {concatenateModules: false, usedExports: false, moduleIds: `named`},
};

/**
Expand All @@ -76,7 +76,7 @@ const clientConfig = {
ssrManifestFilename: `../react-ssr-manifest.json`,
}),
],
optimization: dev ? undefined : {moduleIds: `hashed`},
optimization: dev ? undefined : {moduleIds: `named`},
};

export default [serverConfig, clientConfig];

0 comments on commit 24caf7b

Please sign in to comment.