How to use the into-stream.obj function in into-stream

To help you get started, we’ve selected a few into-stream examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github tracespace / gerber-to-svg / bench / index.js View on Github external
function runStream (source, makeStream, objectMode, done) {
  const targetStream = makeStream()
  const sourceStream = (objectMode)
    ? intoStream.obj(source)
    : intoStream(source)

  endOfStream(sourceStream.pipe(targetStream).resume(), done)
}

into-stream

Convert a string/promise/array/iterable/asynciterable/buffer/typedarray/arraybuffer/object into a stream

MIT
Latest version published 5 months ago

Package Health Score

76 / 100
Full package analysis

Popular into-stream functions