Wednesday 28 August 2019

Sharing code between projects. How do you handle this?

How do you guys manage shared code between your projects. There's various bits of code from our mobile app, website, API, and tooling that are more or less the same. It would be nice to have a symbolic link of sorts between these projects to share this code and keep things DRY. If it was just something on my computer, a symbolic link would be easy enough. But, of course, this is something that's managed with git and npm and such.Creating a dedicated repo and referencing it in package.json seems like the best solution I've found but if you're working on something that requires, e.g., augmenting that shared code, the dev cycle gets incredibly tedious as you now have to push to github, update your package.json, and then install it.Are there tools or features of npm/yarn or git that I'm overlooking that would make this more manageable?

Submitted August 28, 2019 at 05:30PM by HasFiveVowels

No comments:

Post a Comment