Local tasks

Local tasks, otherwise known as tabs, are grouped links that usually show up above the main content of a page (depending on the region where the tabs block is placed). They are usually used to group together related links that have to deal with the current page. For example, on an entity page, such as the Node Details page, you can have two tabs--one for viewing the Node and one for editing it (and maybe one for deleting it),in other words, for local tasks, as shown in the following screenshot:

Local tasks take access rules into account, so if the current user does not have access to the route of a given tab, the link is not rendered. ...

Get Drupal 8 Module Development now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.