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: add prompt to use trpc10 #197

Closed
wants to merge 4 commits into from
Closed

feat: add prompt to use trpc10 #197

wants to merge 4 commits into from

Conversation

juliusmarminge
Copy link
Member

Add option to scaffold with tRPC v10

  • I reviewed linter warnings + errors, resolved formatting, types and other issues related to my work
  • The PR title follows the convention we established conventional-commit
  • I performed a functional test on my final commit

Now that tRPC is sort of stable and got a lot of attention on stream, I thought it would be a good idea to add the ability to scaffold a project using tRPC v10.

As it is still in Alpha, and the API of v10 is not yet finalized, the option to scaffold with v9 is still there as the default, but if people want to use v10 there is now the option to select that via an additional prompt.

See a fully-stacked example app here: juliusmarminge/t3-starters/trpc10-full. It includes all packages.

For a more minimal example, check out this repo: juliusmarminge/t3-starters/trpc10-minimal. It is scaffolded with only trpc10.


Screenshots

Here is a showcase of the scaffolding process:
CleanShot 2022-07-14 at 22 36 18

@nexxeln
Copy link
Member

nexxeln commented Jul 15, 2022

I'm not too sure about how v10 is set up so are you sure this is the right config?

@juliusmarminge
Copy link
Member Author

I'm not too sure about how v10 is set up so are you sure this is the right config?

You mean like folder structure way or? This got all the correct pieces and it follows the same parterns that i used when migrating the tRPC examples over there.

Question is if we include this as a prompt or release create-t3-app@next similar to how tRPC does?

@nexxeln
Copy link
Member

nexxeln commented Jul 16, 2022

Question is if we include this as a prompt or release create-t3-app@next similar to how tRPC does?

Sounds good to me

@ninox14
Copy link

ninox14 commented Jul 16, 2022

i've had an issue when installing packages in generated with this branch
issue with screenshots on trpc repo

basically it generates package.json with wrong names for v10 trpc

    "@trpc/server@experimental": "^10.0.0-alpha.38",
    "@trpc/client@experimental": "^10.0.0-alpha.38",
    "@trpc/next@experimental": "^10.0.0-alpha.38",
    "@trpc/react@experimental": "^10.0.0-alpha.38"

removing @experimental from package names solves this issue

@juliusmarminge
Copy link
Member Author

basically it generates package.json with wrong names for v10 trpc

this seems to be resolved on trpc's end or at least it doesn't happen on my end when i tested now..

Question is if we include this as a prompt or release create-t3-app@next similar to how tRPC does?

Sounds good to me

Closing this and opened up #203

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.

None yet

3 participants