http-code-from-text
v1.0.1
Published
Reverse http.STATUS_CODES
Downloads
1
Readme
httpCodeFromText
Reverse http.STATUS_CODES from Node
Installation
Usage
import {
httpCodeFromText,
textFromHttpCode,
} from "http-code-from-text";
httpCodeFromText[`Ok`] === 200
textFromHttpCode[200] === `Ok` // an alias for http.STATUS_CODES
http.STATUS_CODES[200] === `Ok`