About Composer Packages
Composer packages makes maintaining your code easier. For example, you have a small library which is used in a few projects at the same time. You want to add a new feature or fix a bug.
You can go through all projects which are using the library and update them. But what if new update needs to add new dependencies? You should add them manually too. It will take too much time and chance to break something is very high.
Another way is to package the library in a Composer package and make it accessible somewhere across the Internet (you actually don’t need make it public). In this case you update the code, add required dependencies in config and release a new version. After that, you just go through projects and run a single command in their root directory:
This is much easier than the previous scenario.
PHP developers created many professional tools to make coding easier. One of them is PSR standard. This standard contains recommendations how to organize classes, interfaces and traits naming in your code.