Skip to content

Get the first length-prefixed-message while returning an unconsumed stream

Notifications You must be signed in to change notification settings

juliangruber/peek-length-prefixes-message

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

10 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

peek-length-prefixed-message

Get a stream's first length-prefixed-message while returning an unconsumed stream.

Example

var peek = require('peek-length-prefixed-message')

var stream = createStream()

stream = peek(stream, function (err, buf) {
  // ...
})

Installation

$ npm install peek=length-prefixed-message

API

stream = peek(stream, cb)

License

MIT

About

Get the first length-prefixed-message while returning an unconsumed stream

Resources

Stars

Watchers

Forks

Packages

No packages published