Skip to content

Commit 128c5e2

Browse files
Export interfaces to create type-safe AsyncStorage
1 parent a20c553 commit 128c5e2

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

src/createAsyncStoragePersister/index.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,13 @@
11
import { PersistedClient, Persister } from '../persistQueryClient'
22
import { asyncThrottle } from './asyncThrottle'
33

4-
interface AsyncStorage {
4+
export interface AsyncStorage {
55
getItem: (key: string) => Promise<string | null>
66
setItem: (key: string, value: string) => Promise<void>
77
removeItem: (key: string) => Promise<void>
88
}
99

10-
interface CreateAsyncStoragePersisterOptions {
10+
export interface CreateAsyncStoragePersistorOptions {
1111
/** The storage client used for setting an retrieving items from cache */
1212
storage: AsyncStorage
1313
/** The key to use when storing the cache */

0 commit comments

Comments
 (0)