O'Reilly logo

Drupal 8 Module Development by Daniel Sipos

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Links

Each entity type has a series of links the system needs to know about. Things like the canonical URL, the edit URL, the creation URL, and so on. For the node entities we have the following:

 *   links = { *     "canonical" = "/node/{node}", *     "delete-form" = "/node/{node}/delete", *     "edit-form" = "/node/{node}/edit", *     "version-history" = "/node/{node}/revisions", *     "revision" = "/node/{node}/revisions/{node_revision}/view", *   }

Like the entity keys, these links are common across all entity types (depending on their enabled capabilities). For example, all entity types have a canonical URL and the API allows quickly finding out which one that is from the definition.

One thing to note about these paths is that they need to be defined as routes. ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required