usehooks
usehooks copied to clipboard
A collection of modern, server-safe React hooks – from the ui.dev team
…clicked) or blured
Hi, The "**remove**" method from **useQueue** does remove the first element but is not returning it. Anyone else can confirm? Thank you. BR
The current behavior of the `usePrevious` hook is to always return `null` as the previous value. But in some cases, it makes sense to have a different default value. For...
If sending data too quickly at the start of the hook, it would never accept a first value.
Hi there, I'm currently getting the following error when compiling with [Vite.js](https://vitejs.dev/) ``` VITE v4.3.9 ready in 567 ms ➜ Local: http://localhost:3036/vite-dev/ ➜ press h to show help ✘ [ERROR]...
Just like `useLocalStorage` and `useSessionStorage`, can you add `useCookieStorage` ?
Hi I'm using useLongpress hook, and it's working fine, but when users scrolls, i do not want the event to be fired, or i would have the ability to detect...
Introduced a new hook named `useInputCharacterLimit` which will help us to set a constraint limit of value to enter in any HTMLInputElement.
After running into a issue using client hooks and server rendering, @tylermcginnis referenced/explained (thanks!) why that error is necessary: https://github.com/uidotdev/usehooks/issues/218#issuecomment-1681205155 It turns out, that happened to multiple users: - https://github.com/uidotdev/usehooks/issues/258...
It'd be useful to be able to provide `useScript()` custom attributes that can be added to the generated `` tag. This is useful for things like the Dropbox `Chooser` component...