UNPKG

rafa

Version:

Rafa.js is a Javascript framework for building concurrent applications.

19 lines (12 loc) 290 B
Convert the first upstream message to a done message, then emit to children and detach from the parent stream. <aside> ```js // once(): Stream var stream = Rafa.stream(); var values = []; stream.once().done(v => values.push(v)); stream.write(1).write(2); // values: [1] ``` </aside>