You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
By the time of first getter call, the 2 micro tasks were already created. I could not find a way to inject another micro task (to clear cache) between the 2.
Aurelia micro task queue is based on std browser micro task, probably code for micro task queue can be extracted to create a parallel queue that will execute correctly, as they all resolves to underlying browser queue.
3cp
changed the title
Rendering could happen multiple times (in multiple micro tasks), getterThrottle could cache wrong value
~~Rendering~~ could happen multiple times (in multiple micro tasks), getterThrottle could cache wrong value
May 25, 2018
3cp
changed the title
~~Rendering~~ could happen multiple times (in multiple micro tasks), getterThrottle could cache wrong value
Rendering (actually not rendering, just task) could happen multiple times (in multiple micro tasks), getterThrottle could cache wrong value
May 25, 2018
When clicking "update" button, local
i
is updated, upper levelj
is updated (ea calls subscribers in sync, not async mode).The problem is local
j
is not updated immediately, it will be updated in a micro task due to the 2 way binding.local
get message()
is rendered twice. First time, by locali
change in a micro task, then by localj
change in another micro task.Using
@getterThrottle()
here will cache wrong value "i:2 j:1", the second update "i:2 j:2" is ignored by the cache.app.js
app.html
test.js
test.html
The text was updated successfully, but these errors were encountered: