• Helper to wrap an asynchronous promise result into a React Hook. The current state of the Promise will be returned each time the hook is called as a PromiseState.

    Returns

    The current state of the promise.

    Type Parameters

    • T

    Parameters

    • promise: Promise<T>

      The promise to wrap. Must not change between calls or the hook will re-run.

    Returns PromiseState<T>

Generated using TypeDoc