Closed JPeer264 closed 7 years ago
Yeah, this is something that the chrome team said they were going to be mucking with. I don't completely agree but we should look into this deeper.
@phated I made a little research about this. Unfortunately there is no way around now. Functions like const anon = () => {}
will never be an anonymous function anymore regarding to this.
Only two solutions would act like an anonymous function. The first one I mentioned before and:
// #2 - return an anonymous function inside
var anon = function() {
return function(cb) {
cb();
};
};
taker.task('fn1', taker.parallel(anon(), noop));
For me the second solution is quite unusual, so I guess nobody will ever do that.
Fixed by ffcb04412b824a50adecca4831395c32b1685ce1
In
tree.js
the testshould form a 3 level nested tree
fails asvar anon = fn()
is not directly an anonymous function. The name of the task isanon
as the expected<anonymous>
If you want, I can make an PR in writing the anonymous function directly in
taker.parallel
, this would fix the issue.EDIT:
same for the last test:
should use the proper labels for aliased tasks (nested)