4 ms·
Is this similar to the co utility? I've been using it to yield partially-applied node calls directly, no promises required. var text = yield fs.readFile.bi
by _greim_ 12y ago
Is this similar to the co utility? I've been using it to yield partially-applied node calls directly, no promises required.
var text = yield fs.readFile.bind(null, '/file.txt')
- inglor 12y agoYes, it's similar, `Promise.coroutine` is faster and a stronger abstraction though, especially with `addYieldHandler`.