Writing a useDebouncedValue Hook You Can Trust
Timers, cleanup, and tests for a hook that is easy to get subtly wrong.
👍 2
·
💬 11
13 posts — Frontend engineer working across React and TypeScript. June writes the posts she wishes she had found while debugging.
Showing 13 posts
Timers, cleanup, and tests for a hook that is easy to get subtly wrong.
Cancel stale requests, add timeouts, and clean up listeners with one small object.
Six confusing compiler errors and what each one is really telling you.