Created
September 5, 2020 06:27
-
-
Save ttlg/2db42377009b0d8cb06b713fb3b92759 to your computer and use it in GitHub Desktop.
todo
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import 'package:freezed_annotation/freezed_annotation.dart'; | |
import 'package:flutter/foundation.dart'; | |
part 'todo.freezed.dart'; | |
part 'todo.g.dart'; | |
@freezed | |
abstract class Todo with _$Todo { | |
const factory Todo( | |
String content, bool done, DateTime timestamp, String uid) = _Todo; | |
factory Todo.fromJson(Map<String, dynamic> json) => _$TodoFromJson(json); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Pragmatic architecture using Riverpod