# thunkify

> Turn callbacks, arrays, generators, generator functions, and promises into a thunk

Latest version **2.1.2** (published 2014-06-02) · MIT license · 0 weekly downloads

## Install

```sh
npm install thunkify
pnpm add thunkify
yarn add thunkify
bun add thunkify
```

## Health

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

Positive: no vulnerabilities.

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

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 2.1.2 |
| Published | 2014-06-02 |
| First published | 2013-10-14 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | none |
| Module format | CommonJS |
| Dependencies | 0 |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 859 |
| Maintainers | tjholowaychuk |
| Keywords | thunk, co, generator, generators, promise |

## Links

- npm: https://www.npmjs.com/package/thunkify
- Repository: https://github.com/visionmedia/node-thunkify
- Issues: https://github.com/visionmedia/node-thunkify/issues
- npm.io page: https://npm.io/package/thunkify

## Alternatives

- [flatbuffers](https://npm.io/package/flatbuffers.md) — 6.0M weekly downloads
- [jwt-simple](https://npm.io/package/jwt-simple.md) — 259.5K weekly downloads
- [@exodus/patch-broken-hermes-typed-arrays](https://npm.io/package/@exodus/patch-broken-hermes-typed-arrays.md) — 28.5K weekly downloads
- [@native-to-anchor/buffer-layout](https://npm.io/package/@native-to-anchor/buffer-layout.md) — 12.2K weekly downloads
- [binary-parser-encoder](https://npm.io/package/binary-parser-encoder.md) — 5.3K weekly downloads

## Recent versions

- 2.1.2 (latest) — 2014-06-02
- 2.1.1 — 2014-04-17
- 2.1.0 — 2014-04-17
- 2.0.0 — 2014-04-17
- 1.0.0 — 2014-04-11
- 0.0.1 — 2013-10-14

## README

# thunkify

  Turn a regular node function into one which returns a thunk,
  useful for generator-based flow control such as [co](https://github.com/visionmedia/co).

## Installation

```
$ npm install thunkify
```

## Example

```js
var thunkify = require('thunkify');
var fs = require('fs');

var read = thunkify(fs.readFile);

read('package.json', 'utf8')(function(err, str){
  
});
```

# License

  MIT

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