Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
The wrapped entity will still need to implement the appropriate interface, but the trait will contain the method implementation using the entity view builder. It should also add some setters and getters for the view mode to use.
Comment | File | Size | Author |
---|---|---|---|
#3 | 3134261--rendering-trait--3.patch | 3.73 KB | e0ipso |
Comments
Comment #2
e0ipsoStarting on this.
Comment #3
e0ipsoI ended up putting this into the base class instead.
Comment #4
e0ipsoComment #6
e0ipso