Exporting tRPC routes to another project

Hi everyone. I'm currently running an Electron app, which contains the main project. I also have a NextJS app which handles the website for the download of the Electron app, and it has the application's API un der pages/api, which the Electron app communicates with. I really like using tRPC, so I was wondering if it's possible to somehow infer the tRPC types across the two projects. (These two projects are under different repos)
3 Replies
domi?
domi?OP3y ago
I was thinking, is it possible to generate hard-coded type annotations from the type inference that trpc generates? and just keep that in a file and update it every time I update the API
Unknown User
Unknown User3y ago
Message Not Public
Sign In & Join Server To View
domi?
domi?OP3y ago
thanks, ill take a look
Want results from more Discord servers?
Add your server