Skip to content

Commit

Permalink
revert
Browse files Browse the repository at this point in the history
  • Loading branch information
huozhi committed Jul 7, 2023
1 parent 1090b0c commit 4999af1
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions packages/next/src/build/webpack-config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -1400,7 +1400,7 @@ export default async function getBaseWebpackConfig(
// so that the DefinePlugin can inject process.env values.

// Treat next internals as non-external for server layer
if (layer && WEBPACK_LAYERS.GROUP.server.includes(layer)) {
if (layer === WEBPACK_LAYERS.server || layer === WEBPACK_LAYERS.action) {
return
}

Expand Down Expand Up @@ -1574,7 +1574,7 @@ export default async function getBaseWebpackConfig(
(isEsm && isAppLayer)

if (/node_modules[/\\].*\.[mc]?js$/.test(res)) {
if (layer && WEBPACK_LAYERS.GROUP.server.includes(layer)) {
if (layer === WEBPACK_LAYERS.server || layer === WEBPACK_LAYERS.action) {
// All packages should be bundled for the server layer if they're not opted out.
// This option takes priority over the transpilePackages option.

Expand Down

0 comments on commit 4999af1

Please sign in to comment.