Closed wkeese closed 5 years ago
A change was landed recently in commit 7c8a77fa6a9edc13852dc85458fb5320ec0beab0 that addresses this issue. Right now it lives in the master branch and will be included in the next release.
There are some caveats regarding listening for "update" events as described in PR #222 and in the Collection documentation:
Because the "update" events are not notified when an item is removed from the collection when filtering is enabled, the new filtered behavior is not on by default. We didn't want to break any existing implementations. Pass true
to the new filterEvents
parameter added to Collection#on
.
Ah cool, thanks for the quick response, and funny timing that this just got fixed. So I guess this is a dup of #188.
This code creates a tracked collection of store items that match
priority=high
:If elements with
priority=high
are added/updated/deleted to the store, like below, I get notifications from thetrackedCollection
listener as expected:However, I'm also getting notifications for when elements that don't match the filter are added/updated/deleted to the store:
Is this expected? Seems like a bug.