Modernize your hooks

Speaker(s)
fmfpereira
Experience level
Intermediate
Duration
30 min

About the session:

Hooks have existed in Drupal since its beginnings. In its evolution and up to version 7 (which continues to be the most used Drupal version according to statistics) hooks are the main way to interact with Core and “contrib” modules. 

With the release of Drupal 8, taking advantage of many of the Symfony framework components, the methods of altering and extending the Core and modules dispersed, namely: 

  • Plugins
  • Entities
  • Services
  • Routes
  • Events

Despite the continuous effort to convert the code to object-oriented programming, hooks are still present. In many cases, they are the only way, or the most efficient / effective way, to interact with Drupal. 

This session aims to show some small history, the current status of code conversion and examples of how to implement hooks in a way that is closer to object-oriented programming, thus leveraging all its advantages.

About me:

I am an active member of the Portuguese Drupal Community and the Portuguese Drupal Association.

I helped to organize local/national events and the Drupal Dev Day Lisbon 2018.

This presentation was done at Drupal Day Lisbon [22-Nov-2019] and at Dropsolid HQ [31-Jan-2020].

I'm a newbie and I'm still learning to do public speaking (and trying to feel comfortable with it).