Semaphore allows you to limit the amount of async calls happening between enter() and exit()

This can be useful when limiting the number of http calls, browser api calls, etc either for performance or to work around browser limitations like max Image.decode() calls in chromium being 256.

Hierarchy

  • Semaphore

Constructors

Accessors

Methods

Constructors

Accessors

Methods

  • Parameters

    • count: number = 1

    Returns void