Fetcher<T> constructor

const Fetcher<T>({
  1. required Future<T> fetch(),
  2. required Widget onSuccess(
    1. T data
    ),
  3. dynamic onLoading()?,
  4. Widget onError()?,
  5. Key? key,
})

Implementation

const Fetcher({
  required this.fetch,
  required this.onSuccess,
  this.onLoading,
  this.onError,
  Key? key,
}) : super(key: key);