Quantcast
Channel: Guymon » performance
Viewing all articles
Browse latest Browse all 10

jQuery: throttle / debounce

$
0
0

jQuery throttle / debounce von Ben Alman ist schon etwas älter, aber entweder hatte ich das vorher noch nicht gesehen oder immer vergessen wenn ich diese Funktionalität gebraucht habe.

jQuery throttle / debounce allows you to rate-limit your functions in multiple useful ways. Passing a delay and callback to $.throttle returns a new function that will execute no more than once every delay milliseconds. Passing a delay and callback to $.debounce returns a new function that will execute only once, coalescing multiple sequential calls into a single execution at either the very beginning or end.


Viewing all articles
Browse latest Browse all 10

Trending Articles