init static method

Initialize the SharedPreferences object in the State object's iniState() function.

Implementation

static Future<SharedPreferences> init() async {
  _initCalled = true;
  _prefsInstance ??= await instance;
  return _prefsInstance!;
}