Cannot match any routes. URL Segment: '': When trying to use child routes and Ng2

旧巷老猫 提交于 2019-12-06 05:20:23

You should give different path names until you use pathMatch: 'full'. Forked.

More about the subject in Angular Router: Empty Paths, Componentless Routes, and Redirects.

The router will stop after the first path is matched, which it does in the parent route. I've found it best to use a separate routing module for each router outlet. That being said, you get an ugly (other:route) for the auxilary route in your url. Admittedly, I have found some limitations to using auxiliary routes.

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!