Package Exports
- http-ndjson
This package does not declare an exports field, so the exports above have been automatically detected and optimized by JSPM instead. If any package subpath is missing, it is recommended to post an issue to the original package (http-ndjson) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.
Readme
http-ndjson
Log http requests as ndjson.
Installation
$ npm install http-ndjson
Usage
const httpNdjson = require('http-ndjson')
const http = require('http')
http.createServer((req, res) => {
httpNdjson(req, res).pipe(process.stdout)
res.end()
}).listen()
API
writeStream = httpNdjson(req, res)
Create an http logger. Returns a write stream.