Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fixing debounce race-condition for timeouts
Currently, the first `debounce()`, takes 10secs to run. The second `debounce` in a `setTimeout(debounce, 20)` takes 30secs total (10 for the `debounce` and 20secs for the `setTimeout`). With the unreliability of the `setTimeout` API, we end up having a race-condition, with the test failing (and occasionally passing). Pumping the timeout a few milliseconds solves this. I understand the two run parallel but I wouldn't rely on 5ms to know the difference.
- Loading branch information