mirrored_repositories/flutter_ksubway/lib
import 'package:shared_preferences/shared_preferences.dart';

class ThemePreference {
  static const themeStatus = "theme_status";

  setDarkTheme(bool value) async {
    SharedPreferences prefs = await SharedPreferences.getInstance();
    prefs.setBool(themeStatus, value);
  }

  Future<bool> getTheme() async {
    SharedPreferences prefs = await SharedPreferences.getInstance();
    return prefs.getBool(themeStatus) ?? false;
  }
}
