From 35c6f6c13a04c85f011332b18b7ff2ccaab9b681 Mon Sep 17 00:00:00 2001 From: MOZGIII Date: Sat, 14 Jan 2023 03:41:35 +0400 Subject: [PATCH] fix(middleware/persist): Fix the storage type (#1540) * Fix the storage type * Export StorageValue type --- src/middleware/persist.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/middleware/persist.ts b/src/middleware/persist.ts index 6e49596dd7..519c26977d 100644 --- a/src/middleware/persist.ts +++ b/src/middleware/persist.ts @@ -6,7 +6,7 @@ export interface StateStorage { removeItem: (name: string) => void | Promise } -type StorageValue = { +export type StorageValue = { state: S version?: number } @@ -89,7 +89,7 @@ export interface PersistOptions { * * @default createJSONStorage(() => localStorage) */ - storage?: PersistStorage | undefined + storage?: PersistStorage | undefined /** * Filter the persisted value. *