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
// if an array, iterate through the keys and remove them from each associated group
839
-
if(Array.isArray(keys)){
840
-
keys.forEach(rm)
841
-
}else{
842
-
rm(keys)
843
-
}
839
+
this.instance().runtime.batch(()=>{
840
+
for(letkeyofkeys){
841
+
rm(key)
842
+
}
843
+
})
844
844
returnthis
845
845
// ! This is commented out because the user may still want to keep the data in the collection. If they want to completely delete the data, they should use `.delete()`
846
846
// if it's removed from all groups, delete the data entirely
@@ -856,13 +856,9 @@ export class CollectionInstance<
856
856
clear(groupNames?: KeyOfMap<Groups>|KeyOfMap<Groups>[]): this {
857
857
// this means we want to clear a group, not the whole collection
// currently, this test fails because the default group updates BEFORE the custom group updates. This means we need to update the engine to only emit the event after all the groups have been updated
130
131
test('Computed can watch a default collection group',()=>{
0 commit comments