async_value_notifier 1.0.1 copy "async_value_notifier: ^1.0.1" to clipboard
async_value_notifier: ^1.0.1 copied to clipboard

retracted

An asynchronous variant of ValueNotifier that coalesces multiple value assignments within the same event‑loop turn into a single notification dispatched in a later microtask.

About #

AsyncValueNotifier is an asynchronous variant of ValueNotifier that coalesces multiple value assignments within the same event‑loop turn into a single notification dispatched in a later microtask.

Key benefits:

  • Avoids synchronous listener re‑entrancy corrupting sequential logic.
  • Prevents common Flutter "setState()/markNeedsBuild during build" style exceptions by deferring callbacks until after the current stack unwinds.
  • Optionally suppresses "undo" changes (value changed then restored) and optionally ignores duplicate listener registrations.

Installation #

  1. Run the following command in your project directory:
flutter pub add async_value_notifier
  1. Add the following code to your dart file:
import 'package:async_value_notifier/async_value_notifier.dart';

Usage #

Almost the same as ValueNotifier. For more information, please check example or API reference.

0
likes
0
points
158
downloads

Publisher

unverified uploader

Weekly Downloads

An asynchronous variant of ValueNotifier that coalesces multiple value assignments within the same event‑loop turn into a single notification dispatched in a later microtask.

Repository (GitHub)
View/report issues

Topics

#async #notifier #batching #tweak #performance

License

unknown (license)

Dependencies

flutter

More

Packages that depend on async_value_notifier