awesome-debounce-promise
use-callback-ref
awesome-debounce-promise | use-callback-ref | |
---|---|---|
1 | 1 | |
382 | 285 | |
- | - | |
1.8 | 5.4 | |
over 2 years ago | 21 days ago | |
TypeScript | TypeScript | |
- | MIT License |
Stars - the number of stars that a project has on GitHub. Growth - month over month growth in stars.
Activity is a relative number indicating how actively a project is being developed. Recent commits have higher weight than older ones.
For example, an activity of 9.0 indicates that a project is amongst the top 10% of the most actively developed projects that we are tracking.
awesome-debounce-promise
-
lodash debounce in React functional component not working
I have a functional component built around the React Table component that uses the Apollo GraphQL client for server-side pagination and searching. I am trying to implement debouncing for the searching so that only one query is executed against the server once the user stops typing with that value. I have tried the lodash debounce and awesome debounce promise solutions but still a query gets executed against the server for every character typed in the search field.
use-callback-ref
-
Is it safe to use a useState "setter" function as a callback ref?
I tried Googling for "useState" "callback ref" (and other similar keyword variations) but results weren't helpful, other than @theKashey's excellent use-callback-ref package which I will definitely use elsewhere (e.g. when I need to pass a callback ref to a component that expects a RefObject, or when I need both a callback and to use a ref locally) but in this case all the callback needs to do is set a state variable when the ref changes, so Anton's package seems like overkill here.
What are some alternatives?
use-debounce - A debounce hook for react
react-query - π€ Powerful asynchronous state management, server-state utilities and data fetching for TS/JS, React, Solid, Svelte and Vue. [Moved to: https://github.com/TanStack/query]
formik - Build forms in React, without the tears π [Moved to: https://github.com/jaredpalmer/formik]
SWR - React Hooks for Data Fetching
apollo-client - :rocket: Β A fully-featured, production ready caching GraphQL client for every UI framework and GraphQL server.
state-with-deps - Studying and understanding state with dependency tracking. A technique used in libraries like SWR.
react-hook-form - π React Hooks for form state management and validation (Web + React Native)
TanStack Query - π€ Powerful asynchronous state management, server-state utilities and data fetching for the web. TS/JS, React Query, Solid Query, Svelte Query and Vue Query.
react-hook - β© Strongly typed, concurrent mode-safe React hooks
formik - Build forms in React, without the tears π [Moved to: https://github.com/jaredpalmer/formik]
react-table - βοΈ Hooks for building fast and extendable tables and datagrids for React [Moved to: https://github.com/TanStack/react-table]