cache persistant

This commit is contained in:
2023-08-29 08:03:06 +10:00
parent 0f34c7dfb9
commit 0119875d22

View File

@@ -1,4 +1,4 @@
import { defineStore } from "pinia"; import { DefineStoreOptions, defineStore } from "pinia";
interface CacheItem { interface CacheItem {
url: string; url: string;
@@ -54,4 +54,8 @@ export const useCacheStore = defineStore({
this.cache = []; this.cache = [];
}, },
}, },
persist: true,
} as DefineStoreOptions<string, unknown, unknown, unknown> & {
persist?: boolean;
}); });