You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Build/Test Tools: Fix React Refresh hot reloading for block plugins.
The react-refresh-entry.js script was bundling its own copy of
react-refresh/runtime instead of using the window.ReactRefreshRuntime
global. This created two separate runtime instances: one in the entry
script where hooks were set up, and one as the window global that
plugins use for performReactRefresh(). Since they were different
instances, the refresh never triggered.
This fix splits the webpack development config into two separate
configs:
- Runtime config: bundles react-refresh and exposes it as
window.ReactRefreshRuntime (no externals)
- Entry config: uses window.ReactRefreshRuntime as an external,
ensuring hooks are set up on the same runtime instance
Follow-up to [60055].
Props youknowriad.
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
0 commit comments