pull-abortable
a pull-stream which may be aborted
Last updated 10 years ago by dominictarr .
MIT · Repository · Bugs · Original npm · Tarball · package.json
$ npm install pull-abortable 
SYNC missed versions from official npm registry.

pull-abortable

a pull-stream that may be aborted from the outside.

example

var pull = require('pull-stream')
var Abortable = require('pull-abortable')

var abortable = Abortable()
pull(
  source,
  abortable,
  sink
)
//at any time you can abort the pipeline,
//the source will be cleaned up, and any
//error will be passed to the sink next time it reads.
atAnyTime(function () {
  abortable.abort()
})

// abort the stream and end with an error
abortable.abort(new Error('example'))

License

MIT

Current Tags

  • 4.1.1                                ...           latest (10 years ago)

8 Versions

  • 4.1.1                                ...           10 years ago
  • 4.1.0                                ...           11 years ago
  • 4.0.0                                ...           12 years ago
  • 3.0.0                                ...           12 years ago
  • 2.0.0                                ...           12 years ago
  • 1.1.1                                ...           12 years ago
  • 1.1.0                                ...           12 years ago
  • 1.0.0                                ...           12 years ago
Maintainers (1)
Downloads
Total 32
Today 1
This Week 8
This Month 24
Last Day 3
Last Week 6
Last Month 1
Dependencies (0)
None
Dev Dependencies (2)
Dependents (2)

© 2010 - cnpmjs.org x YWFE | Home | YWFE