broadcast_bus 0.0.2
broadcast_bus: ^0.0.2 copied to clipboard

A new Flutter package project.

broadcast_bus #

Broadcast bus defines a global bus that can be used across your application, completly context free.

Internally, it uses a Stream of String, supporting multiple listeners.

Usage #

It is possible to emit a new value on the bus using:

BroadcastBus().emit('event');

and listening for events (or a specific event):


BroadcastBus().getMainBus().listen((event) { 
    // check the event and react
})

...

BroadcastBus().getFilteredBus('specific event').listen((_) {
    //react to the event
}
0
likes
80
pub points
29%
popularity

Publisher

Unknown

A new Flutter package project.

Homepage
Repository (GitHub)
View/report issues

Documentation

API reference

License

Apache 2.0 (LICENSE)

Dependencies

flutter

More

Packages that depend on broadcast_bus