ZenQueryConfig<T> constructor
const
ZenQueryConfig<T> ({
- Duration? staleTime = const Duration(seconds: 30),
- Duration? cacheTime = const Duration(minutes: 5),
- bool refetchOnMount = true,
- bool refetchOnFocus = false,
- bool refetchOnReconnect = true,
- Duration? refetchInterval,
- bool enableBackgroundRefetch = false,
- int retryCount = 3,
- Duration retryDelay = const Duration(seconds: 1),
- bool exponentialBackoff = true,
- bool persist = false,
- T fromJson()?,
- Map<
String, dynamic> toJson(- T data
- ZenStorage? storage,
- T? placeholderData,
Implementation
const ZenQueryConfig({
this.staleTime = const Duration(seconds: 30),
this.cacheTime = const Duration(minutes: 5),
this.refetchOnMount = true,
this.refetchOnFocus = false,
this.refetchOnReconnect = true,
this.refetchInterval,
this.enableBackgroundRefetch = false,
this.retryCount = 3,
this.retryDelay = const Duration(seconds: 1),
this.exponentialBackoff = true,
this.persist = false,
this.fromJson,
this.toJson,
this.storage,
this.placeholderData,
});