Convert view route parameter to entity Task: Create a view with link to it displayed among node tabs (View, Edit, etc.).

Solution: Create a view with page display and set its path to "node/%node/foo".

Issue: When the page "node/%node/foo" is visited, \Drupal::routeMatch()-&gt;getParameter('node') returns node ID instead of node object.

Is there a simple way to make it return the node object? (Currently I have to alter the view route and set the parameter type.)
Views doesn't use typed arguments as it doesn't understand them anyway. Why do you need that to work? You can just load it where you need it? And if you have code that relies on that being an object then that code is wrong and will also fail on node/N/revisions for example.

What might work is defining such a page with page_manager, that will allow to define the right type.. but on the other hand, page manager does not yet support defining local tasks.