我有一个路由配置,简化并在下面复制。我的问题是,每当我尝试导航到/teams/something/settings/users/invite
时,我立即被重定向到/teams/something/settings/users/list
。我喜欢帮助弄清楚我的导航有什么问题。
警卫都按预期工作。
const settingsRoutes: Routes = [{
path: 'teams/:id/settings',
component: BaseComponent,
children: [{
component: TeamSettingsComponent,
path: '',
children: [{
path: 'users',
children: [{
path: 'invite',
component: InviteUsersComponent,
canDeactivate: [InviteUsersUnsavedChangesGuard]
}, {
path: 'list',
component: UsersComponent,
canDeactivate: [UsersUnsavedChangesGuard]
},
{
path: '',
pathMatch: 'full',
redirectTo: 'list'
}]
}]
}],
}];