gulp-promisify
Enables use of Promises or ES7 async/await keywords to control the flow of Gulp 3 tasks. If using Gulp 4, you should use the .serial()
and .parallel()
methods instead of this module.
Install
$ npm install --save-dev gulp-promisify
Example
;;;; ; { return gulp ;} { return gulp ;} { ; ;} { await ; await ;} gulp;gulp;gulp;gulp;
API
promisify(gulp)
Causes streams returned by .src()
, .dest()
, and .symlink()
to also be Promise objects with .then()
and .catch()
methods. The promise is resolved when the stream emits the 'end'
event. This promisification propagates to all subsequent streams via .pipe()
to ensure that you may await any following stream.
gulp ; // <- returns a promisified stream
Contribute
Standards for this project, including tests, code coverage, and semantics are enforced with a build tool. Pull requests must include passing tests with 100% code coverage and no linting errors.
Test
$ npm test
© 2016 Shannon Moeller me@shannonmoeller.com
Licensed under MIT