AlbertBrand / angular-cancel-on-navigate

MIT License
25 stars 12 forks source link

Usage with ui-router #2

Open edriang opened 8 years ago

edriang commented 8 years ago

Hi, I was very frustrated at first because this library wasn't working OK, but after a while I realized that this module uses $locationChangeSuccess event.

Because I'm using ui-router with states, I simple had to replace that event name with '$stateChangeSuccess' and that solved my issue.

I think it could be helpful for others to make this observation in your README, cause ui-router is basically a standard on these days.

Thanks for the library anyway!

mcelotti commented 7 years ago

I was having the same issue, thanks for the hint!

Makanz commented 7 years ago

Thanks, saved my day.