ui-router / angular

UI-Router for Angular: State-based routing for Angular (v2+)
https://ui-router.github.io/ng2/
MIT License
353 stars 134 forks source link

uiSref doesn't work unless matching "name". Can't use full path/name. #945

Closed stnor closed 2 years ago

stnor commented 3 years ago

I have a hierarchy in my app with loads of states, of which some are lazy. Example:

Screenshot 2021-08-30 at 12 57 49

My expectation is that uiSref="plus.mentees.current.mentee.dashboard" would work, but only "mentee.dashboard" works (since that's the 'name' of the state). Shouldn't fully qualified state paths work in uiSref?

Thanks in advance.

christopherthielen commented 2 years ago

Hi, yes it's expected that fully qualified state name plus.mentees.current.mentee.dashboard should work. It's also surprising that mentee.dashboard works (it's not expected)

When clicking the sref and it fails to work (to plus.mentees.current.mentee.dashboard) I would expect to see some error messages printed in the javascript console with a bit more detail.

stnor commented 2 years ago

Yeah, it's weird. Nothing happens when navigating/clicking and there are no errors. I've since migrated to the Angular Router, but migration would have been a total PITA without this project. Thanks for all your work!