Module Development

Understand the Service Container for Drupal 8

Sprout Video

In this tutorial, we'll shift gears from routes and controllers to services. First off, you'll learn all about the Service Container, also known as the Dependency Injection Container. This is the basis for understanding these special objects called services and how you can leverage them in Drupal.

Additional resources

Dependency Injection and the Art of Services and Containers