getList static method

List? getList(
  1. String key
)

Implementation

static List? getList(String key) {
  String? data = prefs?.getString(key);
  return (data == null || data.isEmpty) ? null : json.decode(data);
}