I'm planning to deploy my frontend and backend separately, and I'm curious if a monorepo is still a good idea in this setup. Considering that different teams might be working on the frontend and backend, I want to know if that affects the choice between monorepo and separate repositories. Have you tried either approach, and what worked best for your projects?
6 Answers
With different teams and development speeds, separate repos make more sense. It allows for flexibility and teams can work at their own pace without stepping on each other's toes.
For our microservices and microfrontends, the monorepo approach is really beneficial. It makes large changes easier to implement rather than having to navigate multiple repos.
I've had great success with monorepos! They're much easier to manage when dealing with multiple services or apps, especially with tools like turbo and pnpm workspaces. Sharing dependencies across services helps a lot with version control and documentation.
I'm more inclined to go for separate repos. I think monorepos can be overhyped. Sure, they have their benefits, but I find that with varying tech stacks, mixing everything into one repo can complicate things. It often doesn't enhance the code-sharing potential as much as you'd wish, and sometimes you end up sacrificing the strengths of individual stacks.
Totally get where you're coming from. It can be tricky when the projects have different needs!
If your teams aren't dedicated to front or back end, a monorepo could work, but it really shines when you're managing lots of services in distributed systems. That structure keeps everything organized better in my experience.
Honestly, it really depends on the size of your team and how you structure things. I've kept frontend and backend together when I work with small teams, and it works out well since we own the whole stack. But I know some companies prefer to split them into different teams.
Exactly! It's crucial to weigh the pros and cons for each scenario.