Skip to content

Commit 79be054

Browse files
committed
misc updates
1 parent 8c0b830 commit 79be054

File tree

4 files changed

+8
-1
lines changed

4 files changed

+8
-1
lines changed

README.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,8 @@
99

1010
## Persistent reactive models in Flutter with zero boilerplate
1111

12+
### NOTE: 2.0 is unstable, use 1.6.0 for now
13+
1214
Flutter Data is a [local-first](https://www.inkandswitch.com/local-first/) data framework with a customizable REST client and powerful model relationships, built on Riverpod.
1315

1416
<small>Inspired by [Ember Data](https://github.com/emberjs/data) and [ActiveRecord](https://guides.rubyonrails.org/active_record_basics.html).</small>

lib/src/adapter/watch_adapter.dart

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -525,6 +525,10 @@ mixin _WatchAdapter<T extends DataModelMixin<T>> on _RemoteAdapter<T> {
525525
DataStateNotifier<T?> notifierFor(T model) {
526526
return watchOneNotifier(model, remote: false);
527527
}
528+
529+
void triggerNotify() {
530+
core._notify([internalType], type: DataGraphEventType.updateNode);
531+
}
528532
}
529533

530534
final coreNotifierThrottleDurationProvider =

lib/src/model/data_model.dart

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,6 @@ mixin DataModelMixin<T extends DataModelMixin<T>> {
3434
String get _internalType => DataHelpers.internalTypeFor(T.toString());
3535
T get _this => this as T;
3636

37-
/// Exposes this type's [Adapter]
3837
Adapter<T> get _adapter => _internalAdaptersMap![_internalType] as Adapter<T>;
3938

4039
T init() {

lib/src/storage/local_storage.dart

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,12 +14,14 @@ class LocalStorage {
1414
final int busyTimeout;
1515

1616
late final String path;
17+
late final bool inIsolate;
1718

1819
@protected
1920
late final Database db;
2021

2122
Future<LocalStorage> initialize({bool inIsolate = false}) async {
2223
if (isInitialized) return this;
24+
this.inIsolate = inIsolate;
2325

2426
final baseDirPath = await baseDirFn();
2527
path = path_helper.join(baseDirPath, 'flutter_data.db');

0 commit comments

Comments
 (0)