Chapter 11: Creating Your Own Composer Package
In this chapter, we are going to continue looking at Composer. This time, we are going to try to create a small but useful package that we can reuse across all of our projects.
The first thing, of course, is to create the actual library that you want to publish. I would encourage you to think twice before publishing an empty "hello world" type package, as Packagist is a real system and there is no benefit in clogging it up with useless libraries.
That being said, let's just make a "hello world" Composer package and try to show some common scenarios. If you decide to upload your version to Packagist, please make sure to remove it once you are done!
You can see the simple "hello world" project that has been created here:
The-Art-of-Modern-PHP-8/composer-module-hello-world at main · PacktPublishing/The-Art-of-Modern-PHP-8 · GitHub
This chapter will cover the...