ReactiveCustomWidget<T extends Widget> constructor

const ReactiveCustomWidget<T extends Widget>({
  1. Key? key,
  2. required T builder(
    1. BuildContext context
    ),
  3. required Stream<void> stream,
})

Creates an instance of ReactiveCustomWidget.

The constructor initializes the widget with a builder function and a stream. The builder function is used to create the widget's content, which is updated in response to changes in the stream.

Example:

ReactiveCustomWidget<Text>(
  builder: (context) => Text('Reactive Content'),
  stream: myUpdateStream,
)

Implementation

const ReactiveCustomWidget({
  super.key,
  required this.builder,
  required this.stream,
});