src/app/modules/user/user.routing.module.ts
Модуль маршрутизации для пользователя
import { RouterModule, Routes } from '@angular/router';
import { NgModule } from '@angular/core';
import { UserComponent } from './user.component';
import { UserHomeComponent } from './home/home';
import { UserEditComponent } from './edit/edit';
const USER_ROUTES: Routes = [
{
path: '', component: UserComponent,
children: [
{path: '', redirectTo: 'home'},
{path: 'home', component: UserHomeComponent},
{path: 'edit', component: UserEditComponent},
]
},
];
/**
* Модуль маршрутизации для пользователя
*/
@NgModule({
imports: [
RouterModule.forChild(USER_ROUTES)
],
exports: [RouterModule]
})
export class UserRoutingModule {
}