initCache static method
Creates storeLocation
in the file system to save serialized objects
storeLocation
is optional for Web
Implementation
static Future<void> initCache(String? storeLocation) async {
if (storeLocation != null) {
Hive.init(storeLocation);
}
await Hive.openLazyBox(cacheName);
}