1.0.2 • Published 9 years ago

httplike v1.0.2

Weekly downloads
32
License
MIT
Repository
github
Last release
9 years ago

httplike

Build Status

node.js package for parsing http-like protocols

Installation

npm install httplike

Usage

var Parser = require('httplike');
var p = new Parser(socket);
p.on('message', function(msg) {
  console.log(msg.method);
  console.log(msg.headers);
  console.log(msg.content);
});

Protocol Assumptions

httplike assumes that the incoming protocol follows HTTP standards on using the Content-Length header to determine how many bytes to wait for in a response body.

Changelog

1.0.1
  • Fixed parsing involving UTF-8 characters (PR #8), and potential stall in pipelined requests (PR #9)
1.0.0
  • Removed parseHeader from public interface on ClientParser and ServerParser
0.0.9
  • Removed dependency on lodash
0.0.7
  • Implemented built-in response object modeled after express.js response.
  • Added trim() to method and headers
0.0.5
  • Breaking changes to how headers are accessed (getHeader() function instead of headers[]). See tests for example usage.
1.0.2

9 years ago

1.0.1

10 years ago

1.0.0

10 years ago

0.0.9

10 years ago

0.0.8

10 years ago

0.0.7

10 years ago

0.0.6

10 years ago

0.0.5

10 years ago

0.0.4

10 years ago

0.0.3

10 years ago

0.0.2

10 years ago

0.0.1

10 years ago