machty / ember-concurrency

ember-concurrency is an Ember Addon that enables you to write concise, worry-free, cancelable, restartable, asynchronous tasks.
http://ember-concurrency.com
MIT License
691 stars 157 forks source link

Fix encapsulated state render updates #383

Closed maxfierke closed 3 years ago

maxfierke commented 3 years ago

This one is a bit in-the-weeds, but it's effectively a bugfix plus a workaround for < 3.16. We're now wrapping TaskInstance internally and externally for EncapsulatedTask launched instances. This is so that internal state updates work. However, for Ember < 3.16, we needed to go a step further and add some additional handlers to the Proxy setup in order to ensure derived state updates get rendered correctly, due to the way the state was stored in those versions.