Skip to content

Commit

Permalink
Docs: Align API with undertaker docs
Browse files Browse the repository at this point in the history
  • Loading branch information
erikkemperman authored and phated committed Dec 31, 2017
1 parent bc352dd commit 0f3151e
Showing 1 changed file with 7 additions and 5 deletions.
12 changes: 7 additions & 5 deletions docs/API.md
Original file line number Diff line number Diff line change
Expand Up @@ -737,7 +737,7 @@ To build your own custom registry see the [undertaker documentation on custom re

#### registry

A registry instance or constructor. When passed in, the tasks from the current registry will be transferred to the new registry and then current registry will be replaced with the new registry.
A registry instance. When passed in, the tasks from the current registry will be transferred to the new registry and then current registry will be replaced with the new registry.

#### Example

Expand Down Expand Up @@ -765,16 +765,18 @@ var DefaultRegistry = require('undertaker-registry');

function MyCompanyTasksRegistry() {
DefaultRegistry.call(this);
}
util.inherits(MyCompanyTasksRegistry, DefaultRegistry);

this.set('clean', function(done) {
MyCompanyTasksRegistry.prototype.init = function(gulp) {
gulp.task('clean', function(done) {
done();
});
this.set('someCompanyTask', function(done) {
gulp.task('someCompanyTask', function(done) {
console.log('performing some company task.');
done();
});
}
util.inherits(MyCompanyTasksRegistry, DefaultRegistry);
};

module.exports = new MyCompanyTasksRegistry();
```
Expand Down

0 comments on commit 0f3151e

Please # to comment.