i want to persist a list that has custom objects and i even wrote method for serializing and de-serializing it but i don't know how to use it with SharedPreferences and FutureBuilder
here is the custom object:
class Fact {
String factText;
Color factColor;
Fact(this.factText, this.factColor);
Map<String, dynamic> toJson() =>
{'factText': factText, 'factColor': factColor};
Fact.fromJson(Map<String, dynamic> json)
: factText = json['factText'],
factColor = json['factColor'];
}