status-codes:节点模块返回带有名称和消息的 HTTP 状态代码对象

时间:2021-06-16 16:22:06
【文件属性】:
文件名称:status-codes:节点模块返回带有名称和消息的 HTTP 状态代码对象
文件大小:6KB
文件格式:ZIP
更新时间:2021-06-16 16:22:06
JavaScript 状态码 返回所有已知 HTTP 状态以及名称和简要说明的小模块。 安装 $ npm install status-codes --save 使用 来自此所有 var statusCodes = require ( 'status-codes' ) ; statusCodes [ 404 ] ; /** Returns: { "status": 404, "name": "Not Found", "message": "The server has not found anything matching the Request-URI." } **/ // OR use a get method that has a fallback to a code 400 if it doesn't find a valid cod
【文件预览】:
status-codes-master
----index.js(12KB)
----package.json(603B)
----LICENSE(1KB)
----.gitignore(587B)
----README.md(2KB)

网友评论