# data-queue

> Queue and get data

Latest version **0.0.3** (published 2017-11-14) · MIT license · 0 weekly downloads

## Install

```sh
npm install data-queue
pnpm add data-queue
yarn add data-queue
bun add data-queue
```

## Health

**Score 15/100 (F)** — status: abandoned.

Positive: no vulnerabilities.

Warnings: low downloads; no types; no esm support; pre 1.0.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 0.0.3 |
| Published | 2017-11-14 |
| First published | 2017-08-11 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | none |
| Module format | CommonJS |
| Dependencies | 0 |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 1 |
| Author | Maciej Krüger |
| Maintainers | mkg20001 |
| Keywords | queue, data, buffer, async |

## Links

- npm: https://www.npmjs.com/package/data-queue
- Repository: https://github.com/mkg20001/data-queue
- Homepage: https://github.com/mkg20001/data-queue#readme
- Issues: https://github.com/mkg20001/data-queue/issues
- npm.io page: https://npm.io/package/data-queue

## Alternatives

- [cron](https://npm.io/package/cron.md) — 4.9M weekly downloads
- [@vercel/queue](https://npm.io/package/@vercel/queue.md) — 731.6K weekly downloads
- [create-sonicjs](https://npm.io/package/create-sonicjs.md) — 1.6K weekly downloads
- [@exellix/jobs-api](https://npm.io/package/@exellix/jobs-api.md) — 941 weekly downloads
- [@forwardimpact/libskill](https://npm.io/package/@forwardimpact/libskill.md) — 575 weekly downloads

## Recent versions

- 0.0.3 (latest) — 2017-11-14
- 0.0.2 — 2017-08-11
- 0.0.1 — 2017-08-11

## README

# data-queue
Queue and get data

# Usage
```js
const Queue = require("data-queue")

const queue = Queue() //create without new

queue.get((err, data) => { //this will wait for .append()/.prepend() or .error() calls
  console.log(data)
  queue.get((err, data) => {
    if (err) throw err //Throw the error
  })
})

queue.append("Hi there")

queue.error(new Error("Something fatal happened"))

queue.append("What's up?") //This won't append the data. instead it will return the error

console.log(queue.height()) //This gets the number of items in the queue
```

---
_Source: https://npm.io/package/data-queue · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
