3.2.1 • Published 17 days ago

bare-http1 v3.2.1

Weekly downloads
-
License
Apache-2.0
Repository
github
Last release
17 days ago

bare-http1

HTTP/1 library for JavaScript.

npm i bare-http1

Only HTTP servers at the moment and currently does NOT support server request bodies, but supports most other HTTP features (keep-alive, chunked encoding, etc.) and streaming server responses.

Usage

const http = require('bare-http1')

// Same API as Node.js

const server = http.createServer(function (req, res) {
  res.statusCode = 200
  res.setHeader('Content-Length', 10)
  res.write('hello world!')
  res.end()
})

server.listen(0, function () {
  console.log('server is bound on', server.address().port)
})

License

Apache-2.0

3.2.1

17 days ago

3.2.0

19 days ago

3.1.0

19 days ago

3.0.0

19 days ago

2.0.5

2 months ago

2.0.4

2 months ago

2.0.3

3 months ago

2.0.2

3 months ago

2.0.1

3 months ago

1.2.0

9 months ago

2.0.0

6 months ago

1.1.3

11 months ago

1.1.2

11 months ago