Views needs a access check class, which allows you to check access by role. It's certainly not really helpful
for code-only routes, though if you configure for example a View people really often uses role based access, primarily
because you don't have an UI for adding new permissions, just for adding roles.
↧
Add role based access checker.
↧