Options
All
  • Public
  • Public/Protected
  • All
Menu

Functions

Functions

Const retry

  • retry<T>(fn: function, condition: boolean, error: string | Error, retryCount?: number): T

Recursively retry a function call

Type parameters

  • T

Parameters

  • fn: function

    The function to retry

      • (...args: unknown []): T
      • Parameters

        • ...args: unknown [] Rest

        Returns T

  • condition: boolean

    Condition based on which the function will be retried. If true, the function will not be retried.

  • error: string | Error

    Error or error message to throw

  • retryCount: number = 2

    Number of times to retry

Returns T

  • Inherited
  • Protected
  • Private
  • Static
  • Module
  • Object
  • Property
  • Function
  • Variable
  • Index
  • Type
  • Class
  • Interface
  • Enum
  • Constructor
  • Getter/Setter
Made with ❤️ by pirix-gh. Documentation generated by TypeDoc.