Popsicle middleware for rejecting responses with bad HTTP statuses.
npm install popsicle-status --save
import { status } from "popsicle-status";
const middleware = status();
const res = await middleware(req, send);
Default status codes of min 200
(inclusive) and max 400
(exclusive).
This project is written using TypeScript and publishes the definitions directly to NPM.
MIT