Hi All,
i’m attempting to use ObjectPromiseProxy
to deal with fetching data from ember-data at lower levels of the app outside of the model hook. Before octane this was as simple as following the pattern to create the proxy and then ember would re-render automatically when it resolved the promise.
promiseObj: computed(function() {
return ObjectPromiseProxy.create({
promise: resolvingPromise(resultObject)
});
}),
This doesn’t appear to be working in octane. The UI never re-renders when the promise resolves.
get promiseObj() {
return ObjectPromiseProxy.create({
promise: resolvingPromise(resultObject)
});
}
It looks like i can hack it to work by just decorating the getter with @computed()
but i’m not sure thats really a fix.
I’m not filling this as a bug… yet… because i assume that there is just some other known pattern that works with octane and is the one i should be using. Can anyone direct me how to do it properly? Or is this really a bug?
Here is a twiddle showing the issue. It takes 5 seconds to resolve the promise and you can see that the octane controller doesn’t re-render where the classic controller does.