• Sleeps for the specified amount of time.

    Type Parameters

    • T extends number

    Parameters

    Returns {
        cancel: (() => void);
        promise: Promise<void>;
    }

    • cancel: (() => void)
        • (): void
        • Returns void

    • promise: Promise<void>