I use aHooks and it really matter, because you can define what you need to execute on throttle or debounce. Also this lib can deal with loading status, auto refresh, etc.
Mohamed Karin work at google as a developer i launch my first project firebase.I have been promised as part of a large communlty of professional developer from innovative starup to global business.
Great stuff. Can anyone recommend a library for throttle/debounce? In the vue world we have VueUse for this sort of thing.
Debouncing is the simplest thing to do. Just code it.
Or am I missing something?
debounce + react async updates (useState, etc) + async fetch might be a bit more complex.
You can look into the JS utility library such as Lodash and Underscore.
I use aHooks and it really matter, because you can define what you need to execute on throttle or debounce. Also this lib can deal with loading status, auto refresh, etc.
rxjs can do that. It used to be bundled with Angular. Not sure about now.
rxjs.dev/api/index/function/debounce
rxjs.dev/api/index/function/throttle
This is awesome, thanks for sharing mate!
Thanks, man.
Very informative 👏
short and crisp
Yeah just like React Component.
more informative
I am glad that you like it.
Great post.
Great insights! Callstack has an excellent guide to React optimization as well :)
Thank for sharing
React high order components could also optimise your code
nice
I don't even know how to use React (yet) what am I even doing ? Anyway it was such a helpful post 👏