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
Create an effect() wherein (only) the keys() of the Map are accessed.
Use set() to update an existing entry in the Map. The effect() is re-invoked, even though the keys() haven't changed.
Note that this makes the behaviour of a Map different to that of a Set, even if the Map is merely used as a Set.
What is expected?
The behaviour of a Map should match that of a Set. Specifically, when a Map key is UPDATED, rather than newly added, effect() should not react as if the list of keys() has changed.
What is actually happening?
The effect() is re-invoked, as if the list of keys() has changed. In the code sample, this causes an extra line of output to be printed.
The text was updated successfully, but these errors were encountered:
Version
3.0.0-alpha.9
Reproduction link
https://jsfiddle.net/kxy9bued/1/
Steps to reproduce
See code sample. To summarise:
Note that this makes the behaviour of a Map different to that of a Set, even if the Map is merely used as a Set.
What is expected?
The behaviour of a Map should match that of a Set. Specifically, when a Map key is UPDATED, rather than newly added, effect() should not react as if the list of keys() has changed.
What is actually happening?
The effect() is re-invoked, as if the list of keys() has changed. In the code sample, this causes an extra line of output to be printed.
The text was updated successfully, but these errors were encountered: