Get notified when a model and its relationships graph is loaded?


#1

One of our models involves a fairly complex relationship graph. We need to find out when the entire graph of descendants is loaded (some associations are embedded, some are async).

Is there a way to do that with Ember Data? I should note I am using Ember Data 0.13, not the new version.

Note: I know it feels like an SO question. But I tried there and did not get any answers…


#2

Just a thought (hopefully, not out of turn, speaking for the community), you should link your SO question from your post. Unfortunately, I can’t be of anymore help, I’m too new and I don’t use Ember Data.


#3

Oh, I am sorry I did not see this got posted. It was an old post I had prepped and not submitted a while back. For some reason (user error I am sure :smile: ) it got posted when I logged in again today.

Anyway here is the SO question: http://stackoverflow.com/questions/18697348/ember-js-how-to-get-notified-when-both-model-and-relationships-have-loaded

I never found a way to make it work nicely. I ended up using observers on the child elements that I knew would be changing. I don’t recommend this solution though, it’s not very good.