Open wardbell opened 8 years ago
AHA!
Only later, when looking at the crisis-center.routes.ts
did I see that both the CRISIS_CENTER
route and its child to CrisisListComponent
are marked with index: true
which is the new useAsDefault
.
CRISIS_CENTER: {
path: '/crisis-center',
component: CrisisCenterComponent,
index: true,
children: [
{ path: '/', component: CrisisListComponent, index: true },
{ path: '/:id', component: CrisisDetailComponent, canDeactivate: [CanDeactivateCrisisDetail] }
]
}
Leaving this issue open to remind us to document it.
This is what the app displays when it launches (no path)
How does it know to display the first route component (CrisisList)? We don't have
useAsDefault
orindexRoute
yet. Even reversing the order of the items in theapp.routes.ts:RouterConfig
doesn't change it.