How to use Composer in Laravel?

What is Composer?

Composer is a tool dependency management in PHP. It allows you to declare the libraries your project depends on and it will manage (install/update) than for you. Composer is not a package manager in the same a Yum or Apt are. Yes, it deals with “packages” or libraries, but it manages them on a per-project basis, installing them in a directory (e.g. vendor) inside your project. By default, it does not install anything globally. Thus, it is a dependency manager. It does however support a “global” project for convenience via the global command.

Why use Composer?

  • You have a project that depend on a number of libraries.
  • Some of thoes libraries epen on other libraries.
  • Enable you to declare the libraries you depend on.
  • Find out which versions of which packeges can and need to be installed, and installs them.

You have a project that depends on several libraries. The libraries that I used in my project to create PDF are also supported by other libraries. It gives you the urgency to declare those libraries that you are on these libraries as it will manage them all for you. It will find out which packages are required for the project we have. Which version of the package is required and will install it for you.

Tagged : / / / /
0 0 votes
Article Rating
Notify of

Inline Feedbacks
View all comments
Would love your thoughts, please comment.x