onValue method
It's called after the memoized function has completed its execution.
Implementation
@override
void onValue(Memo<T, A> memo, A arg, T value, bool fromCache) {
if (!fromCache) {
Future.delayed(duration, () => memo.remove(arg));
}
}