This package has been deprecated

Author message:

Package no longer supported. Use from @codevor/js-http-status

js-http-status

1.0.1 • Public • Published

This package is no longer maintained. Choose @codevor/js-http-status package.

@codevor/js-http-status;

Travis CI Coverage Status NPM Version NPM Downloads Commitizen License

Installation

js-http-status is available on npm/yarn:

$ npm install @codevor/js-http-status --save
$ yarn add @codevor/js-http-status

Documentation

Access documentation clicking here.

Usage

Practice and learn here.

With ES6/import

import {
  findStatusByCode,
  findStatusByKey,
  isCreated,
  isOk
} from 'js-http-status';
 
findStatusByCode(200);
// => { code: 200, key: 'OK', message: 'OK', category: 'SUCCESS' }
 
findStatusByKey('TOO_MANY_REQUESTS');
// => { code: 429, key: 'TOO_MANY_REQUESTS', message: 'Too Many Requests', category: 'CLIENT_ERROR' }
 
isCreated(201); // => true
isCreated(500); // => HTTPStatusError: Expected a 201 response.

Contributing

Please read CONTRIBUTING.md for details on our code of conduct, and the process for submitting pull requests to us.

Changelog

This project adheres to Semantic Versioning. Every release, along with the migration instructions, is documented on the Github Releases page.

Bugs and Sugestions

Report bugs or do suggestions using the issues.

References

License

MIT License © Codevor

Dependencies (0)

    Dev Dependencies (20)

    Package Sidebar

    Install

    npm i js-http-status

    Weekly Downloads

    1

    Version

    1.0.1

    License

    MIT

    Unpacked Size

    2.21 MB

    Total Files

    233

    Last publish

    Collaborators

    • helderburato
    • helderberto