undertaker-forward-reference

Undertaker custom registry supporting forward referenced tasks.

MIT 5 个版本
安装
npm install undertaker-forward-reference
yarn add undertaker-forward-reference
pnpm add undertaker-forward-reference
bun add undertaker-forward-reference
README

undertaker-forward-reference

NPM version Downloads Build Status Coveralls Status

Undertaker custom registry supporting forward referenced tasks.

Why?

The focus of gulp 4.0 is to make the 90% use case extremely easy, but we don't want to completely unsupport the 10% use cases. We have noticed patterns people use and things they want to do (and have worked around), like serial execution. However, I believe forward referenced tasks (as defined in https://github.com/gulpjs/gulp/issues/802) are an edge case that is better handled with other patterns (coming soon: links to better patterns). If you must use forward referenced tasks, you can set this as a custom registry before registering any tasks.

Usage

var gulp = require('gulp');
var FwdRef = require('undertaker-forward-reference');

gulp.registry(FwdRef()); // or gulp.registry(new FwdRef());

gulp.task('default', gulp.series('forward-ref'));

gulp.task('forward-ref', function (cb) {
  // do task things
  cb();
});

API

ForwardReferenceRegistry()

Constructor for the registry. Pass an instance of this registry to gulp.registry.

License

MIT

版本列表
2.0.0 2022-06-28
1.0.2 2017-10-02
1.0.1 2015-12-21
1.0.0 2015-11-17
0.1.0 2015-07-26