-
Several articles on Gulp best practices advocate for using https://github.com/gulpjs/gulp/tree/master/docs/why-use-pump However, articles like this are from the Gulp 3 days. Is such advice still relevant given the "ground-up rewrite" of Gulp 4? And if |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 1 reply
-
@rdhallman import { pipeline } from 'stream'
export const someTask = (done) => {
pipeline(a, b, c, d, done)
} If you use it a lot you could also pipeline vs. pump I think is just personal preference. The way |
Beta Was this translation helpful? Give feedback.
@rdhallman
pipeline
can be used like so:If you use it a lot you could also
promisify
it via the node util so you could just return it and save some syntax.pipeline vs. pump I think is just personal preference. The way
pipeline
works was based off ofpump
/pumpify
(mafintosh projects) so the behavior should be nearly identical - I do know from personal experience thatpipeline
has some edge cases but I think they are resolved as of node 15.