• Sleeps current thread for a specified amount of time

    Parameters

    • microseconds: number = 1000

      the amount of time to sleep, in microseconds

    Returns Promise<void>

    a promise that could be resolved

    sleep(200);
    sleep().then(() => {});