Closed gabrielcsapo closed 4 years ago
Isn't it possible to model this by chaining off of the existing promise? I don't really want to expose both a promise based interface and an evented one if we can help it... :thinking:
@rwjblue this is wanting to listen to broccoli events without being the one to awaiting on the current build. How would I get the finished build if I didn’t want to block on waiting for the current build and knowing when the build started? Please see https://github.com/gabrielcsapo/broccoli-inspector/blob/master/server/index.js
watcher.on('buildSuccess', () => {
socket.emit('buildFinished');
});
this is exactly what I was looking for!
Motivation
I am currently working on a project that requires knowing when a builder has finished without blocking on waiting on the current build.
This allows me to subscribe to events just like the beginNode and endNode events.