In my Angular 14 app using standalone components, I'm not able to get a child route to work properly. I used this route configuration:
{
path: 'clients',
title: 'Existing Clients',
loadComponent: () => import('./app/clients/client-list/client-list.component').then(x => x.ClientListComponent),
children: [
{
path: ':id',
loadComponent: () => import('./app/clients/client-edit/client-edit.component').then(x => x.ClientEditComponent)
}
]
}
If I navigate to ".../clients" then the ClientListComponent
properly loads. If I navigate to ".../clients/xyz" the browser shows the proper path, but the page is still the ClientListComponent
instead of the ClientEditComponent
.
What am I doing wrong here?