Change notify_listeners to diff state #2
Labels
enhancement
New feature or request
good first issue
Good for newcomers
help wanted
Extra attention is needed
Currently, when
notify_listeners
is called, we pass the entire new state object to the listener. This is fine, but a good improvement would be to only pass the parts of the state that have changed, because listeners have access to latest state from the store at all times anyway, and will likely only care about new state.Since any change to the state can have additions or deletions, perhaps this can be best implemented as a diff? The listener would then be passed an object with
:additions
and:deletions
which they can deal with as they choose to.The text was updated successfully, but these errors were encountered: