Advertisement
Guest User

Untitled

a guest
Oct 20th, 2016
54
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. const appRoutes: Routes = [
  2.   { // first layout (here is the first and for now the only one router-outlet
  3.     path: '',
  4.     children: [
  5.       { path: '', component: SiteComponent, pathMatch: 'full' },
  6.       { path: 'install', component: InstallationComponent, canActivate: [ InstallationAuth ] },
  7.       { path: 'login', component: LoginComponent, canActivate: [ LoginAuth ] },
  8.       { path: 'register', component: RegisterComponent },
  9.       { path: 'reset', component: ResetComponent, canActivate: [ LoginAuth ] }
  10.     ]
  11.   },
  12.   { //second layout (personnel should have it's own router-outlet
  13.     path: 'personnel',
  14.     children: [
  15.       { path: '', component: PersonnelComponent, canActivate: [ PersonnelAuth ]},
  16.       { path: 'users', component: UsersComponent, outlet: 'personnel' }
  17.     ]
  18.   }
  19. ];
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement