Skip to content
This repository has been archived by the owner on Jun 10, 2019. It is now read-only.

non-mono-repo, non-Lerna version, with private NPM repo #5

Open
kylecordes opened this issue Apr 14, 2017 · 3 comments
Open

non-mono-repo, non-Lerna version, with private NPM repo #5

kylecordes opened this issue Apr 14, 2017 · 3 comments

Comments

@kylecordes
Copy link
Contributor

This example shows how to split a large Angular application into many pieces, managed in a monorepo. Although fairly popular in 2017, there are also many organizations looking to scale their enterprise Angular projects, who don't want a mono repo.

This idea therefore:

Write a script that processes the contents of this repo and automatically splits it into N separate repos. Then patches up the contents of each one to build locally and push to a private NPM repo.

There are serious developer productivity challenges with this approach. It requires that each separate module be developed separately, versioned, published to a private repo before it can be seen and used by other modules. This in turn, more strongly discourages developers from breaking out code in the most modular way.

Still, with the right tooling and advice such an approach should be workable and would be more valuable to some organizations then this monorepo approach.

@kylecordes
Copy link
Contributor Author

In this variant, use the "Angular Package Format 4" described at ng-conf.

https://docs.google.com/document/d/1CZC2rcpxffTDfRDs6p1cfbmKNLA6x5O-NtkJglDaBVs/preview

@kylecordes
Copy link
Contributor Author

... also consult the new lib quickstart:

https://github.com/filipesilva/angular-quickstart-lib

@kylecordes
Copy link
Contributor Author

Update on what this item means: although the example uses Nx now, nonetheless it is possible to make each library be a valid NPM library, and be publishable. That could be done, in a way that yields a more tedious development experience, but which illustrates the same ideas without anything that resembles a monorepo; some organizations feel very strongly that a group of related applications and libraries should each have their own separate repository. It would be ideal to show an example that works with that constraint.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant