As much as I love open-source, not every project or package is meant to become open-source. Especially commercial projects are usually not released under an open-source license.
For these cases you can use:
Private NPM/yarn packages with a license defined as "UNLICENSED" should do the trick. Make sure to not confuse it the "UNLICENSE", which is open-source.
Private composer packages can use the license key "proprietary" to avoid issues.
That's it. More a public note here than an article, but I guess that's fine.
Since you've made it this far, sharing this article on your favorite social media network would be highly appreciated 💖! For feedback, please ping me on Twitter.