flutter_stream_listener 2.0.0 copy "flutter_stream_listener: ^2.0.0" to clipboard
flutter_stream_listener: ^2.0.0 copied to clipboard

Flutter package the helps manage streams and subscriptions. Built in order to reduce the complexity of having to manually subscribe to streams and cancel subscriptions.

flutter_stream_listener #

Pub flutter_stream_listener codecov style: very good analysis License: MIT

Flutter package the helps manage streams and subscriptions. Built in order to reduce the complexity of having to manually subscribe to streams and cancel subscriptions.

StreamListener #

A Widget which manages a Subscription to a Stream and exposes callbacks: onData, onError, and onDone.

StreamListener<int>(
  stream: Stream.fromIterable([0, 1, 2, 3]), // Stream being subscribed to
  onData: (data) {
    // React to the emitted data
  },
  onError: (error, stackTrace) {
    // Optionally handle errors in the Stream
  },
  onDone: () {
    // Optionally react to when the Stream is closed
  },
  cancelOnError: true, // Defaults to false
  child: const SizedBox(),
)
21
likes
160
pub points
81%
popularity

Publisher

verified publisherfelangel.dev

Flutter package the helps manage streams and subscriptions. Built in order to reduce the complexity of having to manually subscribe to streams and cancel subscriptions.

Repository (GitHub)
View/report issues

Documentation

API reference

License

MIT (license)

Dependencies

flutter

More

Packages that depend on flutter_stream_listener