I have a list of path I want to apply CanActivate to all path except some path.Is there any way in angular to discard some path.
Currently I am applying canActivate to all the URLs.If there are lots of URL,We don't want to apply it to all the URL, I will apply to parent path.
But if we apply to parent it will be applicable to all children also. Is there any way to discard some of the children.
const routes: Routes = [
{ path : '', component: UsersListComponent, canActivate:[AuthenticationGuard] },
{ path : 'add', component : AddComponent, canActivate:[AuthenticationGuard]},
{ path : ':id', component: UserShowComponent },
{ path : 'delete/:id', component : DeleteComponent, canActivate:[AuthenticationGuard] },
{ path : 'ban/:id', component : BanComponent, canActivate:[AuthenticationGuard] },
{ path : 'edit/:id', component : EditComponent, canActivate:[AuthenticationGuard] }
];