Function simpleTryAsync

  • Tries to run an async function and resolves with an object containing either a value if the function resolved or an error if the function rejected.

    Parameters

    • func: any

    Returns Promise<{
        error?: undefined;
        value: any;
    } | {
        error: any;
        value?: undefined;
    }>

Generated using TypeDoc