builder property

Widget Function(BuildContext context, QueryResponse<T> response) builder
final

Updates the widget subtree by providing a latest QueryResponse object to the children.

Each Query instance will rebuild its children twice. First rebuild will be called with this QueryResponse instance:

QueryResponse(
  data: null,
  loading: true,
  error: null,
);

Second rebuild will be called with:

QueryResponse(
  data: data, // null if your future throws exception
  loading: false,
  error: null,  // null if your [future] exited successfully
);

Implementation

final Widget Function(
  BuildContext context,
  QueryResponse<T> response,
) builder;