Composer is an application-level package manager for the PHP applications that provides a standard system for managing dependencies of different libraries and others. Some of the features of composer are:
- dependency resolution for PHP packages
- keeping all packages updated
- support autoloading out of the box
- hooks to execute pre and post commands
To manage dependencies, composer uses composer.json file, which looks like:
Copy to Clipboard
1
{
2
"autoload": {
3
"psr-0": {
4
"": "src/"
5
}
6
},
7
"require": {
8
"php": ">=5.3.2"
9
},
10
"config": {
11
"bin-dir": "bin"
12
}
13
}
Leave A Comment