~/talk

Composer 101

Talkat MidCamp 2019 · 2019-03-21..03-24· [php]
slides:none on file

Composer manages PHP dependencies using three files and one directory: composer.json, composer.lock, the vendor directory and the composer.phar executable. Five commands cover most work: composer require, composer install, composer update, composer remove and composer init. Use semantic versioning with tilde/caret constraints, install composer per-project or globally, never commit vendor but commit composer.lock so everyone gets identical major.minor.patch versions, and include vendor/autoload.php to load packages.

AI-written summary · about

  1. 0:00Introduction and speaker intro
  2. 4:56What is Composer and why it matters
  3. 6:20Typical Composer project structure
  4. 8:05Installing Composer on your system
  5. 13:25Global vs per-project installation
  6. 13:45Creating a composer.json file
  7. 16:59Repositories and package sources
  8. 19:04Adding dependencies with composer require
  9. 21:52Understanding composer.lock and vendor directory
  10. 23:17Committing vendor directory best practices
  11. 28:16Installing dependencies with composer install
  12. 30:20Updating packages with composer update
  13. 34:35Removing packages with composer remove
  14. 36:19Using vendor code with autoload
  15. 38:06Recap of Composer commands
  16. 39:10Resources and further learning
  17. 40:14Q&A session begins
~/search
type to search 6,249 conferences, 138,987 speakers and 185,172 talks
~/help
cmdctrl k
search every conference, speaker and series
/
focus the filter search
h
home
c
conferences
s
speakers
e
series
t
light / dark — the status bar button does the same
?
this help
esc
close this, then clear every filter — or just the search, while you are typing in it

Ignored while you are typing. Pages without a filter rail have no search to focus.