Repository URL to install this package:
|
Version:
3.12.2 ▾
|
var debounce = function debounce(func, waitMs) {
var timeout;
return function () {
for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) {
args[_key] = arguments[_key];
}
clearTimeout(timeout);
timeout = setTimeout(function () {
timeout = null;
func.apply(void 0, args);
}, waitMs);
};
};
export default debounce;