A complete in-memory cache in Flutter. Quickly retrieve an object by context and use it in Stream Builder, Value Listenable Builder or by instance in business logic. All changes will be reflected in both methods.
DynamicCacheProvideris for the injection of the cache on context for use in the three.
Dynamic Cachecan be used directly with
StreamBuilderwidget, but preferably in business logic.
Automaticcache cleaning, with the possibility of setting a time expiration for each item.
- Control notify listeners when the cache is updated.
First, you need to import the package: