Describe the bug
I am Working on a Mono Repo which has thousands line of code. Previously we were on Vite Version 4.4.9 and during that
the plugin was working as expected we were not any hmr invalidate but after upgrading to Vite 5. Now once i update file which exports all messages that is used by all other files now my terminal is bombarded with thousands of hmr invalidate messages.
Sample is attached. Could you help why started hapening now and how can we move to older behaviour. As fixing all files to decouple util function exports and React Components exports is not possible as code base more than 20,000+ files
Could not Fast Refresh ("getCascadingArchivalSelectionError" export is incompatible). Learn more at https://github.com/vitejs/vite-plugin-react/tree/main/packages/plugin-react#consistent-components-exports 3:11:59 PM [vite] hmr update /File1.tsx, /File2.tsx 3:11:59 PM [vite] hmr invalidate /File2.utils.tsx Could not Fast Refresh ("getReplicationTargetSelectionError" export is incompatible). Learn more at https://github.com/vitejs/vite-plugin-react/tree/main/packages/plugin-react#consistent-components-exports
Reproduction
NA
Steps to reproduce
Starting Dev server using vite --host
react({ jsxImportSource: '@emotion/react', babel: { plugins: ['@emotion/babel-plugin'], }, }),
System Info
System:
OS: macOS 15.3
CPU: (12) arm64 Apple M3 Pro
Memory: 516.44 MB / 36.00 GB
Shell: 5.9 - /bin/zsh
Binaries:
Node: 22.9.0
Yarn: 1.22.17
npm: 10.8.3
pnpm: 9.12.1
Browsers:
Chrome: 132.0.6834.160
Safari: 18.3
npmPackages:
@vitejs/plugin-react: 4.3.4 => 4.3.4
@vitejs/plugin-react-swc: 3.3.0 => 3.3.0
rollup: 4.30.1 => 4.30.1
vite: 5.4.13 => 5.4.13
Used Package Manager
pnpm
Logs
No response
Validations
Describe the bug
I am Working on a Mono Repo which has thousands line of code. Previously we were on Vite Version 4.4.9 and during that
the plugin was working as expected we were not any
hmr invalidatebut after upgrading to Vite 5. Now once i update file which exports all messages that is used by all other files now my terminal is bombarded with thousands ofhmr invalidatemessages.Sample is attached. Could you help why started hapening now and how can we move to older behaviour. As fixing all files to decouple util function exports and React Components exports is not possible as code base more than 20,000+ files
Could not Fast Refresh ("getCascadingArchivalSelectionError" export is incompatible). Learn more at https://github.com/vitejs/vite-plugin-react/tree/main/packages/plugin-react#consistent-components-exports 3:11:59 PM [vite] hmr update /File1.tsx, /File2.tsx 3:11:59 PM [vite] hmr invalidate /File2.utils.tsx Could not Fast Refresh ("getReplicationTargetSelectionError" export is incompatible). Learn more at https://github.com/vitejs/vite-plugin-react/tree/main/packages/plugin-react#consistent-components-exportsReproduction
NA
Steps to reproduce
Starting Dev server using
vite --hostreact({ jsxImportSource: '@emotion/react', babel: { plugins: ['@emotion/babel-plugin'], }, }),System Info
System: OS: macOS 15.3 CPU: (12) arm64 Apple M3 Pro Memory: 516.44 MB / 36.00 GB Shell: 5.9 - /bin/zsh Binaries: Node: 22.9.0 Yarn: 1.22.17 npm: 10.8.3 pnpm: 9.12.1 Browsers: Chrome: 132.0.6834.160 Safari: 18.3 npmPackages: @vitejs/plugin-react: 4.3.4 => 4.3.4 @vitejs/plugin-react-swc: 3.3.0 => 3.3.0 rollup: 4.30.1 => 4.30.1 vite: 5.4.13 => 5.4.13Used Package Manager
pnpm
Logs
No response
Validations