Active route after `transition.retry()`
I'm storing a Transition in order to return to that route at a later point.
Expected
transition.retry() should returns me to this route and set correct state.
Current observed behavior
After calling transition.retry() from an action on another route I am returned to the route, the URL changes however the wrong links have the active class
Example
https://ember-twiddle.com/50588f2e4afc9cb99a74bc3eada38a81
Version
Ember 1.12+ ... alpha
@alexspeller thanks for taking a look
Probably related to #10557, #13164
active link classes get properly restored if I call
this.router.set('targetState.routerJsState', transition.state)
before calling transition.retry()
I'm running into the same issue on the latest ember (2.14.x) - the workaround described by @dguettler doesn't seem to work for me. Still experimenting and trying to reproduce a twiddle.
In our case, we have a mixin that does a transition.abort() followed by a transition.retry() 50ms later in the willTransition hook of a route. (this is so we can nicely render a loading animation before the transition for a more seamless experience and avoid UX lockup).
The active state on link-to when switching between a route, just changing the positional parameter for model_id, fails every time (all links with the route, even with different model_ids, gain the active class).
I confirmed that removing the mixin fixes the problem, but am looking for a workaround to force ember to recompute the link-to active states, even if it's a hack for now
EDIT: Here's a twiddle reproducing my issue, along with a workaround
https://ember-twiddle.com/128d462ce1fa0acdebd696338ca3dc14?openFiles=templates.application.hbs%2C
Workaround found here: https://github.com/emberjs/ember.js/issues/10557
I am also seeing this behavior on a EULA acceptance route I configured in ember. The redirect itself works fine, but the link active states are incorrectly displaying to the user.
Still happens with ember-3.8.0
Still a problem in 5.5.0.
Here is a reproduction on stackblitz https://stackblitz.com/edit/ember-cli-editor-output-vbtcxx