Skip to content

Commit

Permalink
revert unrelated changes
Browse files Browse the repository at this point in the history
  • Loading branch information
huozhi committed Oct 25, 2022
1 parent f3e10df commit e35457f
Showing 1 changed file with 5 additions and 3 deletions.
8 changes: 5 additions & 3 deletions packages/next/build/webpack-config.ts
Expand Up @@ -1130,9 +1130,11 @@ export default async function getBaseWebpackConfig(
// so that the DefinePlugin can inject process.env values
const isNextExternal =
// Treat next internals as non-external for server layer
/next[/\\]dist[/\\](shared|server)[/\\](?!lib[/\\](router[/\\]router|dynamic|head))/.test(
localRes
)
layer === WEBPACK_LAYERS.server
? false
: /next[/\\]dist[/\\](shared|server)[/\\](?!lib[/\\](router[/\\]router|dynamic|head))/.test(
localRes
)

if (isNextExternal) {
// Generate Next.js external import
Expand Down

0 comments on commit e35457f

Please sign in to comment.