getInstance static method

Implementation

static Future<SharedPreferencesSingleton?> getInstance() async {
  if (_instance == null) {
    _instance = SharedPreferencesSingleton._internal();
    _sharedPreferences = await SharedPreferences.getInstance();
  }
  return _instance;
}