Skip to content
This repository has been archived by the owner on Mar 23, 2024. It is now read-only.

HTTP Status Codes and Messages

License

Notifications You must be signed in to change notification settings

g-ongenae/magic-http-status

Repository files navigation

HTTP Status Codes and Messages

Build Status Greenkeeper badge

Install

# With yarn
yarn add magic-http-status
# Or with npm
npm i magic-http-status

Why

To easily prevent using magic numbers for HTTP request and not having to recreate each time variable or enums...

Example

import { MESSAGES, CODES } from 'magic-http-status';

response
    .status(CODES.OK)
    .send({
        message: MESSAGES.OK
    });

Releases

No releases published

Packages

No packages published