clear method

  1. @override
Future<void> clear()
override

Removes the value associated with the assigned key from the device's persistent storage.

Implementation

@override
Future<void> clear() async {
  final prefs = await SharedPreferences.getInstance();
  await prefs.remove(key);
}