import { L as Duration, N as Cancel, h as KeyType, r as Store, w as WildcardPath } from "./store-dThvqc0k.js"; //#region src/persist/persistStorage.d.ts interface PersistStorageBase { getItem: (key: string) => string | null | Promise; setItem: (key: string, value: string) => void | Promise; removeItem: (key: string) => void | Promise; } interface PersistStorageWithKeys extends PersistStorageBase { keys: () => string[] | Promise; } interface PersistStorageWithLength extends PersistStorageBase { length: number | (() => number | Promise); key: (keyIndex: number) => string | null | Promise; } interface PersistStorageWithListItems extends PersistStorageBase { listItems: () => Map | Promise>; } type PersistStorage = PersistStorageWithKeys | PersistStorageWithLength | PersistStorageWithListItems; //#endregion //#region src/persist/persist.d.ts type PathOption = WildcardPath | { path: WildcardPath; }; interface PersistOptions { id: string; storage: PersistStorage; paths?: PathOption[]; throttle?: Duration; persistInitialState?: boolean; } declare class Persist { readonly store: Store; readonly options: PersistOptions; readonly storage: PersistStorageWithListItems; readonly [Symbol.dispose]!: Cancel; readonly paths: { path: KeyType[]; throttle?: number; }[]; readonly initialized: Promise; private resolveInitialized?; private channel; private queue; private handles; private stopped; private updateInProgress; private prefix; constructor(store: Store, options: PersistOptions); private watchStore; private watchStorage; private buildKey; private parseKey; private load; private save; stop(): Promise; } declare function persist(store: Store, options: PersistOptions): Persist; //#endregion export { PersistStorageBase as a, PersistStorageWithListItems as c, PersistStorage as i, PersistOptions as n, PersistStorageWithKeys as o, persist as r, PersistStorageWithLength as s, Persist as t }; //# sourceMappingURL=persist-XVT4fROX.d.ts.map