Spaces:
Running
Running
File size: 1,591 Bytes
7a4c35f f4c754b 7a4c35f 3b93905 |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 |
import { Routes } from '@angular/router';
import { authGuard } from './guards/auth.guard';
export const routes: Routes = [
{
path: 'login',
loadComponent: () => import('./components/login/login.component').then(m => m.LoginComponent)
},
{
path: '',
loadComponent: () => import('./components/main/main.component').then(m => m.MainComponent),
canActivate: [authGuard],
children: [
{
path: 'user-info',
loadComponent: () => import('./components/user-info/user-info.component').then(m => m.UserInfoComponent)
},
{
path: 'environment',
loadComponent: () => import('./components/environment/environment.component').then(m => m.EnvironmentComponent)
},
{
path: 'apis',
loadComponent: () => import('./components/apis/apis.component').then(m => m.ApisComponent)
},
{
path: 'projects',
loadComponent: () => import('./components/projects/projects.component').then(m => m.ProjectsComponent)
},
{
path: 'test',
loadComponent: () => import('./components/test/test.component').then(m => m.TestComponent)
},
{
path: 'chat',
loadComponent: () => import('./components/chat/chat.component').then(c => c.ChatComponent)
},
{
path: 'spark',
loadComponent: () => import('./components/spark/spark.component').then(m => m.SparkComponent)
},
{
path: '',
redirectTo: 'projects',
pathMatch: 'full'
}
]
},
{
path: '**',
redirectTo: ''
}
]; |