HasDataChanged<T> typedef
TypeDef for invalidation function which you can pass in get method to run while fetching data from cache in certain interval of time
data
is the cached value that you will get for the key
It should return either updated value or,
null if nothing has changed.
Implementation
typedef HasDataChanged<T> = Future<T?> Function(
{required T data, required String key});