UNPKG

vue-admin-core

Version:
20 lines (16 loc) 356 B
'use strict'; Object.defineProperty(exports, '__esModule', { value: true }); function limit(fn, timespan) { let pending = false; return (...args) => { if (pending) return; pending = true; fn(...args); setTimeout(() => { pending = false; }, timespan); }; } exports.default = limit; //# sourceMappingURL=limit.js.map