s0nerik / context_plus

Convenient BuildContext-based value propagation and observing. Seamlessly integrates with Flutter's built-in observability primitives.
MIT License
32 stars 4 forks source link

icon.png
context_plus

showcase

A set of packages that provide a convenient way to propagate a value from a parent widget to its descendants and observe changes to any observable value.

Packages

Package Pub Description
context_watch context_watch .watch(context)
.watchOnly(context, () => ...)
.watchEffect(context, () => ...)

for Listenable, Future, Stream
context_ref context_ref Ref.bind(context, () => ...)
Ref.bindLazy(context, () => ...)
Ref.bindValue(context, ...)
Ref.of(context)
context_plus context_plus All of context_watch
All of context_ref

+

.watch(context)
.watchOnly(context, () => ...)
.watchEffect(context, () => ...)

for Ref<Listenable>, Ref<Future>, Ref<Stream>

Integrations

Package Pub Description
context_watch_bloc context_watch_bloc .watch(context)
.watchOnly(context, () => ...)
.watchEffect(context, () => ...)

for Bloc and Cubit
context_watch_mobx context_watch_mobx .watch(context)
.watchOnly(context, () => ...)
.watchEffect(context, () => ...)

for Observable
context_watch_getx context_watch_getx .watch(context)
.watchOnly(context, () => ...)
.watchEffect(context, () => ...)

for Rx
context_watch_signals context_watch_signals .watch(context)
.watchOnly(context, () => ...)
.watchEffect(context, () => ...)

for Signal