Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat(react): add support for React Compiler in @nx/react/babel #26826

Merged
merged 1 commit into from
Jul 4, 2024

Conversation

jaysoo
Copy link
Member

@jaysoo jaysoo commented Jul 4, 2024

This PR adds a check in @nx/react/babel preset to enable React Compiler when babel-plugin-react-compiler is installed.

This affects:

  • React apps using Webpack + Babel
  • React libs using Rollup + Babel
  • React Native apps using Webpack + Babel

If SWC is used, there is no way to use React Compiler currently.

Also adds a new recipe showing how to enable the compiler using @nx/react/babel.

Current Behavior

Expected Behavior

Related Issue(s)

Fixes #

@jaysoo jaysoo requested a review from a team as a code owner July 4, 2024 16:58
@jaysoo jaysoo requested a review from ndcunningham July 4, 2024 16:58
Copy link

vercel bot commented Jul 4, 2024

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Updated (UTC)
nx-dev ✅ Ready (Inspect) Visit Preview Jul 4, 2024 7:43pm

@jaysoo jaysoo force-pushed the feat/react-compiler branch from 5cb9fa2 to 11fc71e Compare July 4, 2024 17:12
@jaysoo jaysoo requested a review from a team as a code owner July 4, 2024 17:12
@jaysoo jaysoo force-pushed the feat/react-compiler branch from 11fc71e to 7ddb20b Compare July 4, 2024 17:18
@jaysoo jaysoo requested a review from a team as a code owner July 4, 2024 17:18
@jaysoo jaysoo force-pushed the feat/react-compiler branch from 7ddb20b to fcdabac Compare July 4, 2024 19:26
@jaysoo jaysoo force-pushed the feat/react-compiler branch from fcdabac to 8fc7cb1 Compare July 4, 2024 19:27
@jaysoo jaysoo merged commit 653cad2 into master Jul 4, 2024
6 checks passed
@jaysoo jaysoo deleted the feat/react-compiler branch July 4, 2024 20:18
Copy link

This pull request has already been merged/closed. If you experience issues related to these changes, please open a new issue referencing this pull request.

@github-actions github-actions bot locked as resolved and limited conversation to collaborators Jul 11, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants