delete method

  1. @override
Future<void> delete(
  1. String key
)
inherited

Implementation

@override
Future<void> delete(String key) async {
  checkInitialized();

  if (!data.containsKey(key)) {
    return;
  }

  onDelete.broadcast(
    StoreDeleteEvent(
      key,
      data.remove(key) as T,
    ),
  );

  await persist();
}