UNPKG

@augment-vir/common

Version:

A collection of augments, helpers types, functions, and classes for any JavaScript environment.

15 lines (14 loc) 607 B
import { type MaybePromise } from '@augment-vir/core'; import { type AnyDuration } from '@date-vir/duration'; /** * Creates an interval that prevents multiple parallel executions. If the previous callback * execution is still executing, the next one will not fire. * * @category Interval * @category Package : @augment-vir/common * @package [`@augment-vir/common`](https://www.npmjs.com/package/@augment-vir/common) */ export declare function createBlockingInterval(callback: () => MaybePromise<void>, interval: AnyDuration): { intervalId: NodeJS.Timeout; clearInterval(this: void): void; };