What is Composer
Composer is a new standard for the management of PHP packages and libraries. Basically is used to manage the libraries on which the project depends.
Composer like so:
- Composer is a tool for dependency management in PHP. It allows you to declare the libraries your project and it will manage install/update.
- Enables you to declare the libraries.
- Finds out which versions of which packages can and need to be installed, and installs them.
Composer is actually inspired from npm from Node.js and Bundler from Ruby.
You might also be aware of PEAR. PEAR is an established PHP package manager that has been around for years. PEAR however, has been abandoned by many PHP developers for a number of reasons. Firstly, much of the code in PEAR is out-of-date. Secondly, PEAR forces you to install packages system wide, rather than on a project-by-project basis. This means that if you already have a project that relies on a slightly older package, you are screwed. For an excellent history of PHP packages, read Packages: The Way Forward for PHP by Phil Sturgeon.