containsKey static method
Returns true if persistent storage the contains the given key
.
Return null if key is null
Implementation
static bool containsKey(String? key) {
if (key == null) {
return false;
}
assert(_initCalled, 'Prefs.init() must be called first!');
assert(_prefsInstance != null,
'Maybe call Prefs.containsKeyF() instead. SharedPreferences not ready yet!');
return _prefsInstance?.containsKey(key) ?? false;
}