Last active
May 28, 2019 16:48
-
-
Save illvart/dad73d0ed3ab1be59ca29ff77960bf71 to your computer and use it in GitHub Desktop.
Gulp log
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
const through = require("through2"); | |
const verify = title => { | |
const write = (file, enc, cb) => { | |
console.log("File", file.path); | |
cb(null, file); | |
}; | |
const end = cb => { | |
console.log(`${title} done!`); | |
cb(); | |
}; | |
const options = { objectMode: true }; | |
return through(options, write, end); | |
}; | |
.pipe(verify("yay")); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment