mirror of
https://github.com/hanzoai/next.js.git
synced 2026-09-24 17:00:51 +00:00
This PR ensures that both Webpack and the config won't be initiated in render workers. This is great for performance but also avoids potential issues (e.g. Next.js plugin with side effects). Instead, we pass a serialized config from the router worker to the render workers. Closes #52366.
12 lines
207 B
JavaScript
12 lines
207 B
JavaScript
// This should work
|
|
console.log(require('webpack').sources.RawSource)
|
|
|
|
/** @type {import('next').NextConfig} */
|
|
const nextConfig = {
|
|
webpack(config) {
|
|
return config
|
|
},
|
|
}
|
|
|
|
module.exports = nextConfig
|