vlocode-project - v1.40.0-beta-4
    Preparing search index...

    Function poll

    • Waits for the callback to return a true-ish value which resolves the promise.

      Type Parameters

      • T

      Parameters

      • callback: () => OptionalPromise<undefined | T>

        Callback function

      • timeout: number

        The time in ms if after which the callback did not return a true-ish value is expired

      • interval: number = 50

        The interval at which to execute the callback

      • Optionaloptions: { rejectionMessage?: string; resolveOnTimeout?: boolean }
        • OptionalrejectionMessage?: string

          Optional rejection message when the specified time in ms expired without the callback being resolved

        • OptionalresolveOnTimeout?: boolean

      Returns Promise<T>

      Promise