Compose your Drupal website

hussainweb

Composer is a dependency manager for PHP written along the lines of npm (for Node.js) or Bundler (for Ruby). While this might not sound useful to you as a site builder, it will be. Composer is already a defacto standard to use when building PHP applications and now Drupal websites.

Composer was introduced in Drupal world with Drupal 8 and with Drupal 8.1, the core development moved to the accepted composer workflow. At the time, Drupal Packagist was a purely community run service but it is now fully supported by Drupal Association on official Drupal.org infrastructure making Composer the best way to manage your website build now.

In this session, you will learn how Composer workflow helps you in building and maintaining websites with relative use. It might sound intimidating and lot of work at first, not to mention you need to use the terminal, but didn’t you fall in love with drush once you used it? You will learn how to use composer with existing templates and some helpful commands and tools to get you started quickly.

Specifically, you will learn:

  • What composer is and how to use it to build a Drupal 8 website

  • The role of Packagist in composer and also the Drupal packagist supported by Drupal Association

  • Drupal Packagist templates to quickly start with a Drupal 8 website project

  • Best practices in structuring a Drupal 8 website, modules, themes, libraries, profiles, all contributed or custom

  • Best practices in version controlling the website

  • Best practices in using composer in continuous integration environment

  • Patching Drupal core, modules, themes, and profiles

  • Including composer.json from custom modules, if any

  • How to understand common composer errors and fix them

  • Common tools to work with composer

Program tags

automation, devops, php

Experience Level

Beginner

Drupal Version