Composer is a standard way to make and use reusable components. Nowadays, a lot of stuff has already been done and can be reused. For this reason, in PHP, Composer is a standard method. In this chapter, we have seen how Composer works, what it's usages are, how can one install packages through it, and a lot more. However, one thing that we haven't touched on in this chapter is how we can make packages for Composer. This is because our focus was on how we can reuse already available Composer packages. If you want to learn how to a create Composer package, then start from here: https://getcomposer.org/doc/02-libraries.md.
If you want to know more about Composer, you can:
- Go and read Composer documentation at https://getcomposer.org/doc/.
- Open and start reading important files. You can open and read different Composer files, such as
composer.json
andcomposer.lock
, from different packages.
Till now, we have seen how we can reuse Composer components to avoid writing everything on our own...