load method
Load the last saved preferences.
Implementation
@override
Future<DevicePreviewData?> load() async {
final json = await file.readAsString();
if (json.isEmpty) return null;
return DevicePreviewData.fromJson(jsonDecode(json));
}
Load the last saved preferences.
@override
Future<DevicePreviewData?> load() async {
final json = await file.readAsString();
if (json.isEmpty) return null;
return DevicePreviewData.fromJson(jsonDecode(json));
}