Last updated January 25, 2017
Module Development8.9.x/9.0.x

On occasion you may need to modify the behavior of entity types defined by another module. Thankfully Drupal includes several alter hooks that can be used to override the behavior of another entity.

In this tutorial we will:

  • Walk through the common Entity API hooks
  • Look at example implementations of each
  • And discuss the use cases for each

By the end of this tutorial you will have a better understanding of how to override the default behavior of an entity type provided by Drupal core (or another contributed module) within your custom code.