Skip to content
pubscout

fbroadcast

2.0.0, released 4 years ago by an unverified publisher

An efficient broadcast system for message sending, receiving, and state management in Flutter.

WASM-ready
$ flutter pub add fbroadcast
Source repository

What it does

FBroadcast provides a broadcasting system allowing widgets and modules to communicate through messages, supporting sticky broadcasts, two-way communication, and context binding for easy unregistering.

AI-written summary of version 2.0.0, based on the package's README and metadata. Report an inaccuracy

Use it when

  • You want complete decoupling between widgets or modules without using complex state managers.
  • You need sticky broadcasts that can be queued before a receiver is registered.
  • You need simple two-way communication between decoupled modules.

Skip it when

  • You prefer structured, predictable reactive state management architectures like Bloc or Riverpod.
  • Your project requires strict type safety for every message and payload.

Strengths

  • Enables complete decoupling between widgets and modules.
  • Supports sticky broadcasts and two-way communication.
  • Context binding allows batch removal of receivers easily.

Weaknesses

  • Relies heavily on string-based keys which can become difficult to maintain at scale.
  • Can make data flow harder to trace compared to explicit state containers.

Setup

Kind
Flutter widgets
Effort
Low
Code generation
No
Direct dependencies
0
FBroadcast.instance().register(Key_Message, (value, callback) {
  var data = value;
});

FBroadcast.instance().broadcast(Key_Message, value: data);

Alternatives

Packages that do the same job and could replace fbroadcast.

  • data_widget

    Flutter widgets and helpers for InheritedWidget, ValueNotifier, and state management utilities.