Answer the question
In order to leave comments, you need to log in
How to change the parent component?
There is a module:
@NgModule({
declarations: [ModuleLayoutComponent],
imports: [
CommonModule,
RouterModule.forChild([{path: '', pathMatch: 'full', component: ModuleLayoutComponent, children: [
{path: '/order', component: OrderComponent},
{path: '/payment', component: PaymentComponent}
]}])
],
})
<header></header>
<div class="content">
<router-outlet></router-outlet>
</div>
<footer></footer>
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question