Allow for optional merging of Object type option props
Open
Component: tasks
Type: Enhancement
- Dominant language
- JavaScript
- Stars
- 12.2k
- Forks
- 1.5k
- PR merge metrics
- No merged PRs in 30d
Description
Augment `this.options()` method with one more argument to allow for properties of type Object to merge instead of overwrite.
case:
``` js
multiTask: {
options: {
anObject: {
a: 1
}
},
target: {
options: {
anObject: {
b: 2
}
}
}
}
// in the task
grunt.registerMultiTask('multiTask', function() {
var options = this.options({}, true);
// desired result
// options.anObject === {a:1, b:2}
});
```
Contributor guide
Assessment
This issue has not been assessed yet.