# express-promise-patch

> Patch express application object with promise capabilities

Latest version **1.0.4** (published 2017-12-22) · ISC license · 0 weekly downloads

## Install

```sh
npm install express-promise-patch
pnpm add express-promise-patch
yarn add express-promise-patch
bun add express-promise-patch
```

## 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 | 1.0.4 |
| Published | 2017-12-22 |
| First published | 2017-04-25 |
| Weekly downloads | 0 |
| License | ISC |
| TypeScript types | none |
| Module format | CommonJS |
| Dependencies | 3 |
| Known vulnerabilities | 0 |
| Install scripts | no |
| Author | Ori Calvo |
| Maintainers | oricalvo |

## Links

- npm: https://www.npmjs.com/package/express-promise-patch
- npm.io page: https://npm.io/package/express-promise-patch

## Dependencies (3)

- [typescript](https://npm.io/package/typescript.md) ^2.6.2
- [@types/node](https://npm.io/package/@types/node.md) ^8.5.2
- [build-utils](https://npm.io/package/build-utils.md) ^1.0.90

## Recent versions

- 1.0.4 (latest) — 2017-12-22
- 1.0.3 — 2017-12-22
- 1.0.2 — 2017-04-25
- 1.0.1 — 2017-04-25

## README

# express-promise-patch

Monkey patches express application instance with promise aware implmenetation

```javascript
const express = require("express");
const {patch: patchWithPromiseSupport} = require("express-promise-patch");

//const app = express();
const app = patchWithPromiseSupport(express());

app.get("*", function(req, res) {
    return Promise.resolve({
        id: 123,
        name: "Ori"
    }).then(obj => {
        throw new Error("Ooops");
    });
});

app.listen(3000, function() {
    console.log("Server is running");
});

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