debounce (with leading/trailing, cancel, flush)
Comes up in: Coding, UI coding
This concept is being written. It gets the full five steps — explanation, predict, interview angle, practice with tests, and review cards. Here is exactly what it will cover, so you can study it elsewhere in the meantime.
What it covers
- trailing debounce
- preserving
thisand args - leading option
cancelandflush- maxWait
- returning a promise variant
Words you will know
What you will practise
- implement with tests (worked → faded → timed)
Interview questions this answers
- Implement
debounce. Addleadingandcancel.