Closed this issue 8 years ago · 1 comments
thenjs Thenjs(start, [debug]) 中的 start 能否用用有名函数代替,demo中都是匿名函数,若是能参数怎么传递,是否能给个例子,谢谢
如果是函数,只能接收 function (callback) { ... } 形式的函数,如果你要传参,那只能这样:
function (callback) { ... }
function test (a, b) { return function (callback) { ... } } thenjs(test(a, b)).then(...)