FE-715: Fix petrinaut react-compiler issues in dev build pipeline#8718
FE-715: Fix petrinaut react-compiler issues in dev build pipeline#8718alex-e-leon wants to merge 1 commit into
Conversation
|
The latest updates on your projects. Learn more about Vercel for GitHub.
1 Skipped Deployment
|
PR SummaryLow Risk Overview Reviewed by Cursor Bugbot for commit ac77e4a. Bugbot is set up for automated code reviews on this repo. Configure here. |
There was a problem hiding this comment.
Cursor Bugbot has reviewed your changes and found 1 potential issue.
❌ Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, enable autofix in the Cursor dashboard.
Reviewed by Cursor Bugbot for commit 5b8ab83. Configure here.
🤖 Augment PR SummarySummary: Prevent React Compiler from running on prebuilt workspace 🤖 Was this summary useful? React with 👍 or 👎 |
5b8ab83 to
63c8972
Compare
63c8972 to
ac77e4a
Compare

🌟 What is the purpose of this PR?
React Compiler's
validateNoRefPassedToFunctionrule was firing on the bundled output of @hashintel/ds-components. The library's source uses standard JSX (<button ref={ref} ... />), which the compiler permits — but tsup (via esbuild) compiles JSX into explicitjsx("button", { ref, ... })calls - which causesvalidateNoRefPassedToFunctionto fail.Since Vite follows the workspace symlink from node_modules/@hashintel/ds-components to libs/@hashintel/ds-components/dist/, the default node_modules exclude didn't match and the babel plugin ran the compiler over the bundled output.
This fixes the issue by having react-compiler ignore the pre-built ds-components export.
Pre-Merge Checklist 🚀
🚢 Has this modified a publishable library?
This PR:
📜 Does this require a change to the docs?
The changes in this PR: