Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/aquariuslt/http-core-constants
http-core constants typescript/javascript version (from apache http-components:httpcore)
https://github.com/aquariuslt/http-core-constants
Last synced: 7 days ago
JSON representation
http-core constants typescript/javascript version (from apache http-components:httpcore)
- Host: GitHub
- URL: https://github.com/aquariuslt/http-core-constants
- Owner: aquariuslt
- License: mit
- Created: 2020-01-20T08:32:23.000Z (almost 5 years ago)
- Default Branch: master
- Last Pushed: 2024-10-28T18:16:06.000Z (10 days ago)
- Last Synced: 2024-10-28T19:29:25.378Z (10 days ago)
- Language: TypeScript
- Size: 1.29 MB
- Stars: 0
- Watchers: 3
- Forks: 1
- Open Issues: 29
-
Metadata Files:
- Readme: README.md
- Changelog: CHANGELOG.md
- License: LICENSE
Awesome Lists containing this project
README
# Node Http Constants
[![NPM](https://img.shields.io/npm/v/http-core-constants.svg)](https://www.npmjs.com/package/http-core-constants) [![Github Workflow Status](https://github.com/aquariuslt/http-core-constants/workflows/ci/badge.svg)](https://github.com/aquariuslt/http-core-constants) [![codecov](https://codecov.io/gh/aquariuslt/http-core-constants/branch/master/graph/badge.svg)](https://codecov.io/gh/aquariuslt/http-core-constants) [![Semantic-Release](https://img.shields.io/badge/%20%20%F0%9F%93%A6%F0%9F%9A%80-semantic--release-e10079.svg)](https://github.com/semantic-release/semantic-release)
Provide http-constants: (standard)headers and status code from java version `org.apache.httpcomponents:httpcore`
## Usage
```typescript
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
```