1.0.0 • Published 5 years ago

pull-append v1.0.0

Weekly downloads
4
License
MIT
Repository
github
Last release
5 years ago

pull-append

append a value to the end of a pull stream.

example

var Append = require('pull-append')
var pull = require('pull-stream')

pull(
  pull.values([1,2,3]),
  Append(function () {
    return 40
  }),
  pull.collect(function (err, ary) {
    console.log(ary) // => [1, 2, 3, 40]
  })
)

Append(last) => Through

return a through stream that passes through it's input unchanged except that the return value of last() is appended.

if the source ends in an error, the error is passed immediately, without adding last()

License

MIT