DataBuilder<T> typedef Null safety

DataBuilder<T> = Widget Function(BuildContext context, T data)

This function takes a context and data of type T and returns a widget

Used when bloc updates its state and widget needs to rebuild with new data

Implementation

typedef DataBuilder<T> = Widget Function(BuildContext context, T data);