removeEntity method

void removeEntity(
  1. String type,
  2. String id
)

Remove canonical entity, patches, and entity state.

Implementation

void removeEntity(String type, String id) {
  _write(() {
    _entities[type]?.remove(id);
    _patches[type]?.remove(id);
    _entityStates.remove(_ek(type, id));
    _syncMetadata.remove(_ek(type, id));
    removeIdFromAllLists(type, id);
    _notifyRemoved(type, id);
  });
}