installing them in a directory (e.g. vendor) inside your project. By default it does not install anything globally. It does however support a “global” project for convenience via the global command.
Composer is strongly inspired by node's npm and ruby's bundler.
In a Composer project:
dependencies are defined in a composer.json file,
while their specific versions are locked in a composer.lock file.