http-core-constants
TypeScript icon, indicating that this package has built-in type declarations

1.3.0 • Public • Published

Node Http Constants

NPM Github Workflow Status codecov Semantic-Release

Provide http-constants: (standard)headers and status code from java version org.apache.httpcomponents:httpcore

Usage

import { HttpHeaders, HttpStatus, HttpRequestMethod } from 'http-core-constants';

console.log(HttpHeaders.ACCEPT);    // output: Accept
console.log(HttpStatus.SC_OK);      // output: 200 (constants with `SC` prefix same as apache core constants)
console.log(HttpStatus.OK);         // output: 200
console.log(HttpRequestMethod.GET); // output: GET

Package Sidebar

Install

npm i http-core-constants

Weekly Downloads

221

Version

1.3.0

License

MIT

Unpacked Size

22.7 kB

Total Files

14

Last publish

Collaborators

  • aquariuslt