We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 1392c51 commit 9cb1c67Copy full SHA for 9cb1c67
src/middleware/persist.ts
@@ -126,7 +126,10 @@ export interface PersistOptions<S, PersistedState = S> {
126
* A function to perform persisted state migration.
127
* This function will be called when persisted state versions mismatch with the one specified here.
128
*/
129
- migrate?: (persistedState: unknown, version: number) => S | Promise<S>
+ migrate?: (
130
+ persistedState: unknown,
131
+ version: number,
132
+ ) => PersistedState | Promise<PersistedState>
133
/**
134
* A function to perform custom hydration merges when combining the stored state with the current one.
135
* By default, this function does a shallow merge.
0 commit comments