Change record status: 
Project: 
Introduced in branch: 
9.3.x
Introduced in version: 
9.3.0
Description: 

Named views arguments representing entities are upcasted now. For example the %user argument, validated as an user entity, will allow the following code to get directly the user entity, rather than the raw user ID:

$account = \Drupal::routeMatch()->getParameter('user');
assert($account instanceof \Drupal\user\UserInterface);
Impacts: 
Module developers