Angular 对特定路由器链路和所有子路由使用*ngIf=
问题:在父路由的所有子路由中显示[content],即。Angular 对特定路由器链路和所有子路由使用*ngIf=,angular,routes,wildcard,router,Angular,Routes,Wildcard,Router,问题:在父路由的所有子路由中显示[content],即。[content]以使./parent/child1、./parent/child2、./parent/child2(n)全部显示[content] 建议的解决方案:[content]或变体[content],似乎不被角度框架所接受 文件: 基于将Fiehra的答案作为建议的解决方案:使用*ngIf=“router.url.includes('/parent/)来划分引用父路由的子路由。解决了我的问题 您是否尝试过完美的解决方案。谢谢。
[content]
以使./parent/child1、./parent/child2、./parent/child2(n)全部显示[content]
建议的解决方案:[content]
或变体[content]
,似乎不被角度框架所接受
文件:
基于将Fiehra的答案作为建议的解决方案:使用*ngIf=“router.url.includes('/parent/)来划分引用父路由的子路由。解决了我的问题
您是否尝试过完美的解决方案。谢谢。