Please log in to watch this conference skillscast.
Consider starting a new project when modularity is at the forefront of your architectural mind; you might think you'll have 5 packages, and each will have a corresponding git repository. While this may sound like a modular dream, I can speak from experience that it isn't! These are some things that you can expect to face when you have separate git repositories that are highly dependent on each other:
Friction around pull requests that cut across multiple packages
Broken builds due to bad changes in separate repositories
Time spent around pull request coordination
Code out of sync across the different repos
Lerna to the rescue! If you are not aware of what a monorepo is, this is a good starting place, for what, why, and how; with some good previous discussion. These are some of the things that we have happily embraced as a result of using lerna:
Code will always be in sync, one pull request will complete one feature
Master will never be broken
Code reviews happen in one place
No code in dependent repos/packages
Faster CI cycle time
YOU MAY ALSO LIKE:
- React & Redux: Web Application Workshop with Damjan Vujnovic (Online Workshop on 12th - 16th September 2022)
- Advanced JavaScript Workshop with Damjan Vujnovic (Online Workshop on 26th - 28th September 2022)
- FullStack eXchange: In-Person Conference (in London on 27th - 28th July 2022)
- FullStack eXchange: Online Conference (Online Conference on 27th - 28th July 2022)
- Vue.js and TypeScript: Working Together like Peanut Butter and Jelly (SkillsCast recorded in February 2022)
- How We Migrated 65K Lines of Javascript Code to Haskell: Good, Bad and Ugly (SkillsCast recorded in November 2021)
Lightning Talk: Breaking the Monolith a Monorepo - Intermediate
Will Monk
Will is a developer with experience in lots of parts of the stack, and a keen interest in functional programming, and developer experience. For the last 5 years he's been helping big organisations re-platform onto modern frontend and node based stacks. Most recently Will has helped The Trainline on their move to a full react/node based desktop website.