filmov
tv
Angular Route Guard - Part 1 : canActivate guard using CanActivateFn
Показать описание
Angular CanActivateFn provides functional approach to write code for canActivate route guard.
To perform canActivate route guard, we need to know following points.
1. CanActivateFn : Signature of a function to perform canActivate route guard.
2. canActivate : A property of Route interface that accepts an array of CanActivateFn instances.
3. mapToCanActivate : Maps injectable classes containing a method named as canActivate to an array of equivalent CanActivateFn.