Quantcast
Viewing all articles
Browse latest Browse all 4828

Ember route's model hook doesn't re-fired when qp change

@neeleshsaxena wrote:

We recently upgraded to Ember 3.8 and noticed that it messed up a few things in routes. I’m not sure if it’s an actual issue with Ember or something that we did wrong to begin with, so any comments/answers would be welcome.

Understanding: We have a queryParams object with a few properties which have refreshModel: true. We’d expect that once we transitionTo({ queryParams: {...newProps } }), we’ll refire the model hook.

To be very clear, the first time we enter the route, we set undefined to all props in qP. And we transtionTo (with values) through our callbacks.

Behavior: We do see the url being changed with params, but somehow the model hook is overlooked and is not triggered. This is easily traceable as I have 2 versions of my app, one with Ember 3.8 and one with Ember 3.5.1. Model hook is re-fired in Ember 3.5.1, but not in 3.8.

Question: Being new to Ember, I would like to get some feedback on if my understanding is correct? If yes, then has anyone else noticed model hook not being fired when qp (refreshModel: true) change? And is there a way to fix it?

Posts: 1

Participants: 1

Read full topic


Viewing all articles
Browse latest Browse all 4828

Trending Articles