-
-
Notifications
You must be signed in to change notification settings - Fork 19
Description
Describe the bug
Posted this on the discord but told to move it out to here.
Trying to migrate a fairly big work project over to rolldown-vite and am getting errors with plugin-react v5. I didn't have this problem in v4 so I assume it's something to do with adding OXC into the plugin
You may have to download the project from Stackblitz and run locally as the WASM version doesn't seem very happy.
When ran locally, the server boots, but if you open the page you'll see that there's a console error
Uncaught SyntaxError: Identifier 'RefreshRuntime' has already been declared
This has replaced a previous error that mentioned oxc compilation issues, that I cannot replicate now.
I have been highlighted that there might also be a related issue in the plugin-react repo vitejs/vite-plugin-react#346
Reproduction
Steps to reproduce
I have found that this only occurs when using react-compiler. Removing it from the babel plugins fixes the issue.
System Info
System:
OS: macOS 15.5
CPU: (11) arm64 Apple M3 Pro
Memory: 1.43 GB / 36.00 GB
Shell: 5.9 - /bin/zsh
Binaries:
Node: 20.19.0 - ~/.volta/tools/image/node/20.19.0/bin/node
Yarn: 3.2.4 - ~/Dev/Bots/portal/node_modules/.bin/yarn
npm: 10.8.2 - ~/.volta/tools/image/node/20.19.0/bin/npm
bun: 1.2.8 - ~/.bun/bin/bun
Browsers:
Brave Browser: 138.1.80.124
Edge: 139.0.3405.86
Safari: 18.5
npmPackages:
@vitejs/plugin-react: 5.0.0 => 5.0.0
rolldown-vite: 7.1.1Used Package Manager
yarn
Logs
No response
Validations
- Follow our Code of Conduct
- Read the Contributing Guidelines.
- Read the docs and the Rolldown-related guide.
- Check that there isn't already an issue that reports the same bug to avoid creating a duplicate.
- Check that this is a concrete bug. For Q&A open a GitHub Discussion or join our Discord Chat Server.
- The provided reproduction is a minimal reproducible example of the bug.