Provide an option to log Fast Refresh debugging information #62553
kyleschaeffer
started this conversation in
Ideas
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
Goals
Non-Goals
No response
Background
Our team performed an upgrade of a large Next.js application from version
13.4.19
to the latest14.1.0
, which appears to have included significant changes to the way the HMR server handles fast refresh vs. full page reloads. Even after several large-scale attempts to revise components and code to adhere to the limitations and tips provided by the official Next.js documentation, we continue to encounter what appear to be random full page reloads, and have thus far been unable to determine exactly what is triggering them.We have no idea why this happens, and have unfortunately been unable to debug this issue because the HMR server provides no information as to what triggers an HMR update vs. a full page reload. The full page reloads are particularly disruptive because some tasks (such as working with features that await long-running fetch responses, or working with features that use session-based states) have become extremely difficult to perform.
Proposal
A straightforward way to provide access to HMR debugging information would be to surface a new argument in the
next dev
CLI command:While enabled, I would expect the dev server output to be agumented with additional information about each incremental compilation:
Beta Was this translation helpful? Give feedback.
All reactions