UNPKG

ts-retry

Version:

A little retry tool to execute a function until the function is successful. Can also bind a timeout to a function. This lib is usable in typescript, in javascript, in node, in SPA tools (rest, Vue, Svelte...) and browser (available in ESM and common js fo

4 lines (3 loc) 260 B
import { RetryUtilsOptions } from "../options"; import { RESPONSE_TYPE } from "./type"; export declare function retryAsyncUntilResponse<RETURN_TYPE extends RESPONSE_TYPE>(fn: () => Promise<RETURN_TYPE>, retryOptions?: RetryUtilsOptions): Promise<RETURN_TYPE>;