getDouble method

Future<double> getDouble(
  1. String key, {
  2. double defValue = 0.0,
})

Implementation

Future<double> getDouble(String key, {double defValue = 0.0}) async{
  SharedPreferences pref = _pref!;
  double value = pref.getDouble(key) ?? defValue;
  return value;
}