Description
This fiddle shows the difference in order of $destroy and $stateChangeSuccess between 0.2.15 and 0.2.16
https://jsfiddle.net/n3emkeo7/
This change broke our application, and I think it could be quite a significant breaking change.
My guess is that it's something to do with 1be1379 (unconfirmed).
Our use case:
We have a navigation control which listens for $stateChangeSuccess
and subsequently updates the URL using $state.go
.
In 0.2.15 this was fine if you navigated to a different page, the navigation control was destroyed before the $stateChangeSuccess
event was fired, so the control would only redirect the user if they were navigating to a child state.
In 0.2.16 the $stateChangeSuccess
event is fired before the control is destroyed, causing the user to be trapped on the page with the navigation control regardless of if they are trying to navigate away from the page.