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): update app and lib generators to support new TS solution setup #28808

Open
wants to merge 65 commits into
base: master
Choose a base branch
from

Conversation

jaysoo
Copy link
Member

@jaysoo jaysoo commented Nov 5, 2024

This PR updates app and lib generators in the following packages such that they will generate files with the TS solution setup if it is detected.

  • @nx/react
  • @nx/next
  • @nx/remix
  • @nx/expo
  • @nx/react-native

React apps and libs will be linked using npm/pnpm/yarn/bun workspaces feature rather than through tsconfig paths. This means that local aliases like @/ will work with Next.js and Remix apps.

Note: This will be behind --workspaces flag when using npx create-nx-workspace and choosing React stack. If you use the None/TS stack then adding plugins like nx add @nx/react then generating apps, it will automatically pick up the new TS solution setup.

Current Behavior

React generators are not compatible with TS solution setup (i.e. workspaces + TS project references).

Expected Behavior

React generators work with new TS solution setup (Plain, Next.js, Remix, Expo, React Native).

Related Issue(s)

#28322

Copy link

vercel bot commented Nov 5, 2024

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

1 Skipped Deployment
Name Status Preview Updated (UTC)
nx-dev ⬜️ Ignored (Inspect) Visit Preview Nov 22, 2024 7:10pm

@jaysoo jaysoo force-pushed the feat/ts-solution-react branch 9 times, most recently from a454c45 to a2e9734 Compare November 12, 2024 13:09
Copy link

🐳 We have a release for that!

This PR has a release associated with it. You can try it out using this command:

npx [email protected] my-workspace

Or just copy this version and use it in your own command:

0.0.0-pr-28808-0f14212
Release details 📑
Published version 0.0.0-pr-28808-0f14212
Triggered by @jaysoo
Branch feat/ts-solution-react
Commit 0f14212
Workflow run 11804472060

To request a new release for this pull request, mention someone from the Nx team or the @nrwl/nx-pipelines-reviewers.

@jaysoo jaysoo changed the title feat(react): update app and lib generators to support new TS solution… feat(react): update app and lib generators to support new TS solution setup Nov 13, 2024
@jaysoo jaysoo marked this pull request as ready for review November 13, 2024 15:33
jaysoo and others added 23 commits November 20, 2024 13:32
…nfig.app.json__tmpl__

Co-authored-by: Nicholas Cunningham <[email protected]>
…config.app.json__tmpl__

Co-authored-by: Nicholas Cunningham <[email protected]>
…sconfig.app.json__tmpl__

Co-authored-by: Nicholas Cunningham <[email protected]>
Copy link

🐳 We have a release for that!

This PR has a release associated with it. You can try it out using this command:

npx [email protected] my-workspace

Or just copy this version and use it in your own command:

0.0.0-pr-28808-a9a1b13
Release details 📑
Published version 0.0.0-pr-28808-a9a1b13
Triggered by @jaysoo
Branch feat/ts-solution-react
Commit a9a1b13
Workflow run 11940032773

To request a new release for this pull request, mention someone from the Nx team or the @nrwl/nx-pipelines-reviewers.

Copy link

🐳 We have a release for that!

This PR has a release associated with it. You can try it out using this command:

npx [email protected] my-workspace

Or just copy this version and use it in your own command:

0.0.0-pr-28808-8717441
Release details 📑
Published version 0.0.0-pr-28808-8717441
Triggered by @jaysoo
Branch feat/ts-solution-react
Commit 8717441
Workflow run 11941506824

To request a new release for this pull request, mention someone from the Nx team or the @nrwl/nx-pipelines-reviewers.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants