Building and maintaining multiple development projects comes with a unique set of problems teams need to solve. How do you share common bits of code between projects? How do you sync dependencies across projects? How do you optimize collaboration between projects?

With solutions to those problems, it’s not shocking to see that monorepos are rapidly growing in popularity. In fact, we use monorepos here at Ionic! Several monorepo tools are available to development teams: Nx, Yarn workspaces, npm workspaces, Lerna, Turborepo…and I’m sure more that I’m not even aware of.

In this blog post we’ll be building out a monorepo using Lerna. I personally like how lightweight it is, and it works well with Ionic Framework React projects and Ionic Appflow.

Our monorepo will consist of three packages (monorepo speak for subprojects); two Ionic Framework React applications, and a shared React library that will supply a React context each application will use.

#ionic

Ionic and Lerna and Rollup, oh my!
1.60 GEEK