RxBuilder constructor
RxBuilder({
- Key? key,
- required Widget builder(
- BuildContext context
- bool filter()?,
Listen for RxNotifier changes present in the builder
method.
builder: All RxNotifier used in this function will be automatically
signed and this function will be called every
time the value of an RxNotifier changes.
filter
: Filter reactions and prevent unwanted effects.
Widget build(BuildContext context){
return RxBuilder(
builder: (_) => Text('${counter.value}'),
);
}
Implementation
RxBuilder({
Key? key,
required this.builder,
bool Function()? filter,
}) : super(key: key) {
_filter = filter;
_stackTrace = StackTrace.current;
}