retryAsync

external fun <T> retryAsync(name: String, method: () -> Promise<T>, getStatusCode: (arg0: T) -> Number?, maxAttempts: Number = definedExternally, delay: Number = definedExternally, onError: (JsError) -> T?? = definedExternally): Promise<T>(source)