await-q

1.0.4 • Public • Published

AwaitQ

Await pop value from queue. If is there, return it. Otherwise, wait until new value.

Example

import { AwaitQ } from "await-q";

const queue = new AwaitQ();

setTimeout(() => queue.push("await-q"), 5000);
const packageName = await queue.pop();

Readme

Keywords

none

Package Sidebar

Install

npm i await-q

Weekly Downloads

0

Version

1.0.4

License

ISC

Unpacked Size

3.72 kB

Total Files

6

Last publish

Collaborators

  • joselcvarela