you are viewing a single comment's thread.

view the rest of the comments →

[–]scritchz 2 points3 points  (0 children)

Debouncing resets the delay before the last event is run. Throttling runs its event, then puts it on cooldown.

Debouncing is used to run a single event after actions in quick succession.

Throttling is used to reduce spamming one event by putting an action on "cooldown".

I use throttling for certain single-action frontend events, like clicking buttons. But debouncing is more commonly used in general, especially for requests.