From 68f6a6a24bcd559b322eed89e92184f159df7c06 Mon Sep 17 00:00:00 2001 From: Srinivasan M Date: Sat, 27 Jan 2024 17:20:31 +0000 Subject: [PATCH] resolved defaultValue not set in session storage --- packages/@mantine/hooks/src/use-local-storage/create-storage.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/@mantine/hooks/src/use-local-storage/create-storage.ts b/packages/@mantine/hooks/src/use-local-storage/create-storage.ts index a12dd8be5d8..235511cb413 100644 --- a/packages/@mantine/hooks/src/use-local-storage/create-storage.ts +++ b/packages/@mantine/hooks/src/use-local-storage/create-storage.ts @@ -150,7 +150,7 @@ export function createStorage(type: StorageType, hookName: string) { useEffect(() => { if (getInitialValueInEffect) { - setValue(readStorageValue()); + setStorageValue(readStorageValue()); } }, []);