_ankri
_ankri
TtRPC
Created by _ankri on 6/27/2023 in #❓-help
Is there a version of tRPC v10 that works with Next 12?
Hi, is there a version of tRPC that works with Next 12 and React 17? We want to incrementally adopt Next 13 and React 18 and also introduce tRPC. But we sadly have to start with Next 12 and React 17 to get there eventually. --- Some more context: We're currently in a version-deadlock situation. We want to incrementally migrate our Express React 17 project to the latest Next 13, React 18 and latest tRPC. We sadly cannot just use Next 13, because Next 13 uses React 18. We cannot just use React 18, because our version of React Router does not support React 18. We also use a component library (we want to get rid of in the long run) that also does not support React 18. What we've done with a similar project: We created a new Next 12 project and redirected the /api calls to our express backend. For the frontend we just used Next with React Router and ported the frontend and backend routes one by one. Now we also want to introduce tRPC. We thought about doing the same as before. Creating a Next 12 project. First redirecting /api to express backend and use React Router on the frontend. Then incrementally porting the routes to Next 12 but porting the /api calls to tRPC. Afterwards we would replace the component library and then make the jump to Next 13. In short: - Use Next 12 instead of Express + CRA - Make it work without using any Next features - Port the api to tRPC - Get rid of React Router and use /pages - Replace old component library - Make the jump to Next 13 and React 18 - Migrate to /app directory Has anybody undertaken such an endeavor? Or do you maybe have some tips for us?
2 replies