Using the search on, you can find packages to add common features, such as image manipulation or PDF generation to your application. Indicators of good packages beyond the number of downloads and the number of stars on GitHub are the quality of documentation, the test coverage, and the overall project activity. Before adding a new package, you can also browse the different versions of a package and its

dependencies on Packagist:laravel frame

In development it is fine to use a dev-master branch, but in production, it is better to stick with a precise version number to avoid potential compatibility issues.

To install a package, open composer.json in a text editor and insert its name and the desired version in the require object:

"require": {
  "laravel/laravel": "v5.1.*",
  "intervention/image": "dev-master"

Since it is a JSON file, you need to be careful not to leave any trailing commas on the last line. To check if there are any errors in your composer.json file, you can use the composer validate command.

Then, simply run composer install and Composer will fetch the package and its dependencies. To update the composer.lock file and save the exact version numbers of the resolved dependencies, call composer update. If you deploy or distribute your application, the lock file allows everyone else to retrieve the exact same packages when they run composer install. The update command, on the other hand, will always check for the latest version of every package and if you run it in production, you risk running into compatibility issues.