cindel_annotations 0.2.1
cindel_annotations: ^0.2.1 copied to clipboard
Public annotations and schema metadata types for the Cindel NoSQL local database.
example/README.md
Cindel annotations example #
Define your persistent models with annotations from cindel_annotations, then
generate the Cindel schema and typed accessors with cindel_generator.
import 'package:cindel_annotations/cindel_annotations.dart';
part 'todo.g.dart';
@Collection(name: 'todos')
class Todo {
Id id = autoIncrement;
@index
late String title;
@Index(type: CindelIndexType.value)
late bool completed;
}
Run the generator from the package that owns the model:
dart run build_runner build --delete-conflicting-outputs