Drupal 8 Services and dependency injection | Drupal 8

Drupal 8 Services and dependency injection

Submitted by editor on Thu, 07/07/2016 - 13:58

What is the Services and dependency injection in Drupal 8 ?


Drupal 8 introduces the concept of services to decouple reusable functionality and makes these services pluggable and replaceable by registering them with a service container.

As a developer, it is best practice to access any of the services provided by Drupal via the service container to ensure the decoupled nature of these systems is respected.

Links : 

The Symfony 2 documentation


Add new comment

Plain text

  • No HTML tags allowed.
  • Lines and paragraphs break automatically.
  • Web page addresses and email addresses turn into links automatically.