Launch Week Day 1: Socket for Jira Is Now Available.Learn More
Socket
Book a DemoSign in
Socket

popsicle-status

Package Overview
Dependencies
Maintainers
1
Versions
13
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

popsicle-status

Popsicle middleware for rejecting responses with bad HTTP statuses

latest
Source
npmnpm
Version
3.0.0
Version published
Weekly downloads
40K
4.12%
Maintainers
1
Weekly downloads
 
Created
Source

Popsicle Status

NPM version NPM downloads Build status Test coverage

Popsicle middleware for rejecting responses with bad HTTP statuses.

Installation

npm install popsicle-status --save

Usage

import { status } from "popsicle-status";

const middleware = status();

const res = await middleware(req, send);

status(min?: number, max?: number)

Default status codes of min 200 (inclusive) and max 400 (exclusive).

TypeScript

This project is written using TypeScript and publishes the definitions directly to NPM.

License

MIT

Keywords

popsicle

FAQs

Package last updated on 09 Jun 2019

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts