Skip to content

feat(LocalStorage): set initialValue#368

Open
ElizabethT7 wants to merge 1 commit into
masterfrom
feature/local-storage-value
Open

feat(LocalStorage): set initialValue#368
ElizabethT7 wants to merge 1 commit into
masterfrom
feature/local-storage-value

Conversation

@ElizabethT7
Copy link
Copy Markdown
Contributor

No description provided.

@ElizabethT7 ElizabethT7 requested review from feerzlay and va25j and removed request for va25j November 28, 2024 07:44
return;
}

localStorage.setItem(key, raw ? (initialValue as unknown as string) : serializer(initialValue));
Copy link
Copy Markdown
Collaborator

@feerzlay feerzlay Nov 28, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

  1. В options нужно добавить некий параметр для включения этого поведения
  2. Лучше перенести в useMemo, перед return initialValue

@ElizabethT7 ElizabethT7 force-pushed the feature/local-storage-value branch from c48e5af to 26a01f4 Compare November 28, 2024 09:56
@ElizabethT7 ElizabethT7 requested a review from feerzlay November 28, 2024 09:56
@feerzlay feerzlay force-pushed the master branch 2 times, most recently from 8fb8e68 to f12d8ab Compare March 13, 2025 09:28
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants