Skip to content

Commit 0847435

Browse files
Merge pull request #235 from jeniabrook/main
Export type declaration for `useSessionStorage`
2 parents 3adff6c + c8f9bda commit 0847435

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

index.d.ts

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -231,6 +231,11 @@ declare module "@uidotdev/usehooks" {
231231
}
232232
): "idle" | "loading" | "ready" | "error";
233233

234+
export function useSessionStorage<T>(
235+
key: string,
236+
initialValue: T
237+
): [T, React.Dispatch<React.SetStateAction<T>>];
238+
234239
export function useSet<T>(values?: T[]): Set<T>;
235240

236241
export function useSpeech(text: string, options?: SpeechOptions): SpeechState;

0 commit comments

Comments
 (0)