# unthenify

> Callbackify a promise function. The logical reverse of `thenify`.

Latest version **2.0.0** (published 2018-02-06) · Apache-2.0 license · 0 weekly downloads

## Install

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

## Health

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

Positive: has types; no vulnerabilities; high quality score.

Warnings: low downloads; no esm support.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 2.0.0 |
| Published | 2018-02-06 |
| First published | 2015-12-30 |
| Weekly downloads | 0 |
| License | Apache-2.0 |
| TypeScript types | bundled |
| Module format | CommonJS |
| Dependencies | 1 |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 0 |
| Author | Blake Embrey |
| Maintainers | blakeembrey |
| Keywords | thenify, promise, callback, nodeify, then |

## Links

- npm: https://www.npmjs.com/package/unthenify
- Repository: https://github.com/blakeembrey/unthenify
- Issues: https://github.com/blakeembrey/unthenify/issues
- npm.io page: https://npm.io/package/unthenify

## Dependencies (1)

- [util-arity](https://npm.io/package/util-arity.md) ^1.0.2

## Alternatives

- [@clerk/clerk-expo](https://npm.io/package/@clerk/clerk-expo.md) — 133.6K weekly downloads
- [@pothos/plugin-authz](https://npm.io/package/@pothos/plugin-authz.md) — 12.4K weekly downloads
- [@bounded-sh/client](https://npm.io/package/@bounded-sh/client.md) — 3.2K weekly downloads
- [@luigi-project/plugin-auth-oauth2](https://npm.io/package/@luigi-project/plugin-auth-oauth2.md) — 2.3K weekly downloads
- [@nocobase/plugin-verification](https://npm.io/package/@nocobase/plugin-verification.md) — 2.0K weekly downloads

## Recent versions

- 2.0.0 (latest) — 2018-02-06
- 1.0.4 — 2016-12-30
- 1.0.3 — 2016-12-30
- 1.0.2 — 2016-06-20
- 1.0.1 — 2016-02-11
- 1.0.0 — 2015-12-30

## README

# Un-thenify

[![NPM version][npm-image]][npm-url]
[![NPM downloads][downloads-image]][downloads-url]
[![Build status][travis-image]][travis-url]
[![Test coverage][coveralls-image]][coveralls-url]

> Callbackify a promise function. The logical reverse of [`thenify`](https://www.npmjs.com/package/thenify).

## Installation

```sh
npm install unthenify --save
```

## Usage

Wrap a function that usually returns a promise to accept callbacks.

```js
import { unthenify } from 'unthenify'

const handler = unthenify(async function (payload) {
  // Do something...

  return true
})

// Use with callback-style.
handler({}, function (err, result) {
  console.log(err, result) //=> undefined, true
})
```

## License

Apache 2.0

[npm-image]: https://img.shields.io/npm/v/unthenify.svg?style=flat
[npm-url]: https://npmjs.org/package/unthenify
[downloads-image]: https://img.shields.io/npm/dm/unthenify.svg?style=flat
[downloads-url]: https://npmjs.org/package/unthenify
[travis-image]: https://img.shields.io/travis/blakeembrey/unthenify.svg?style=flat
[travis-url]: https://travis-ci.org/blakeembrey/unthenify
[coveralls-image]: https://img.shields.io/coveralls/blakeembrey/unthenify.svg?style=flat
[coveralls-url]: https://coveralls.io/r/blakeembrey/unthenify?branch=master

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