From b85413d0bdd6f4f468fcadeacb4c4056e3671ce1 Mon Sep 17 00:00:00 2001 From: Ilya Kantor Date: Sat, 22 Aug 2020 10:46:56 +0300 Subject: [PATCH] Update task.md --- .../09-call-apply-decorators/04-throttle/task.md | 2 ++ 1 file changed, 2 insertions(+) diff --git a/1-js/06-advanced-functions/09-call-apply-decorators/04-throttle/task.md b/1-js/06-advanced-functions/09-call-apply-decorators/04-throttle/task.md index 0ab09e64..6df7af13 100644 --- a/1-js/06-advanced-functions/09-call-apply-decorators/04-throttle/task.md +++ b/1-js/06-advanced-functions/09-call-apply-decorators/04-throttle/task.md @@ -12,6 +12,8 @@ The difference with debounce is that it's completely different decorator: - `debounce` runs the function once after the "cooldown" period. Good for processing the final result. - `throttle` runs it not more often than given `ms` time. Good for regular updates that shouldn't be very often. +In other words, `throttle` is like a secretary that accepts phone calls, but bothers the boss (calls the actual `f`) not more often than once per `ms` milliseconds. + Let's check the real-life application to better understand that requirement and to see where it comes from. **For instance, we want to track mouse movements.**