-
Notifications
You must be signed in to change notification settings - Fork 27.7k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
HMR warnings after upgrading to Webpack 5.10.0 #19865
Comments
Likely related to #18678 |
Duplicate of #18678 |
I can't reproduce this warning with the latest version of webpack 5 and next@canary 🤔 |
@timneutkens I just checked out canary and I'm still seeing these warnings in |
@timneutkens I have a small repro here — https://github.com/paambaati/nextjs-webpack-worker-bug-repro |
I was able to workaround this by prepending Taken from Discussion: Update: Turns out this workaround also breaks the hot reloading. Code changes trigger full page reloads. :( |
My workaround is to add Below is my module.exports = {
future: {
webpack5: true,
},
webpack: (config, { isServer, dev, webpack }) => {
console.log(`Webpack version: ${webpack.version}`);
config.output.hotUpdateMainFilename =
"static/webpack/[fullhash].[runtime].hot-update.json";
if (!isServer) {
config.resolve.fallback.fs = false;
}
return config;
},
}; This is based on Nextjs' default config: next.js/packages/next/build/webpack-config.ts Lines 898 to 900 in cd9bb98
|
Can we please reopen this? Still seeing those warnings in Next.js 11. |
Please open a new issue with a full reproduction. |
Will do, thanks! |
Sorry, I'm not able to provide a full reproduction since I don't know what's causing it. I'll open a new issues when having more information and using workaround from #19865 (comment) in the meantime. |
Updates the hotUpdateChunk to include `[runtime]` for web workers support. Fixes #26152 Fixes #19865 Fixes #26144 ## Bug - [ ] Related issues linked using `fixes #number` - [ ] Integration tests added ## Feature - [ ] Implements an existing feature request or RFC. Make sure the feature request has been accepted for implementation before opening a PR. - [ ] Related issues linked using `fixes #number` - [ ] Integration tests added - [ ] Documentation added - [ ] Telemetry added. In case of a feature if it's used or not. ## Documentation / Examples - [ ] Make sure the linting passes
Updates the hotUpdateChunk to include `[runtime]` for web workers support. Fixes vercel#26152 Fixes vercel#19865 Fixes vercel#26144 ## Bug - [ ] Related issues linked using `fixes #number` - [ ] Integration tests added ## Feature - [ ] Implements an existing feature request or RFC. Make sure the feature request has been accepted for implementation before opening a PR. - [ ] Related issues linked using `fixes #number` - [ ] Integration tests added - [ ] Documentation added - [ ] Telemetry added. In case of a feature if it's used or not. ## Documentation / Examples - [ ] Make sure the linting passes
This issue has been automatically locked due to no recent activity. If you are running into a similar issue, please create a new issue with the steps to reproduce. Thank you. |
Bug report
After upgrading to Webpack 5.10.0, I see this warning a lot on the console —
Everything seems to work fine, though.
To Reproduce
Steps to reproduce the behavior, please provide code snippets or a repository:
next
to run a Next.js app in dev mode.Expected behavior
No warnings.
Screenshots
N/A
System information
next
(Dev mode)Additional context
N/A
The text was updated successfully, but these errors were encountered: