更加实用的 interval
const interval = new Interval(f, {
debounceInterval: 2000,
onStart: () => {
console.log('onStart');
},
onStop: () => {
console.log('onStop');
},
});
interval.start();
const interval = new Interval(f, {
debounceInterval: 2000,
onStart: () => {
console.log('onStart');
},
onStop: () => {
console.log('onStop');
},
});
interval.start();
npm i @iskl/interval
0
1.0.0
ISC
29.4 kB
7