node.js – How to structure a project that uses nodejs in backend and nextjs in frontend?

I’m building an app using Nodejs in the backend and Nextjs in the frontend.
I’m wondering whether the backend and frontend should be in separate repos or should I use a monorepo that contains both frontend and backend.

I want to know the pros and cons for each approach. And what should I keep in mind when it comes to configuration especially if I’ll use a monorepo since I already have a nextjs and nodejs typescript apps setup in separate repos.

I couldn’t find guides on this on the internet.

Read more here: Source link