antares
antares copied to clipboard
Accept complete and error props In 3rd argument to `on`
A handler attached via on
may want to have its completion and error notifications be of a certain type. Currently the type
property of the 3rd argument specifies how to wrap next
notifications, this issue would bring it full cycle, so the author would not need to resort to concat
and processResults: true
as is necessary in a case like below.
return concat(
from(goodLines.map(line => ({ type: "goodLine", payload: line }))),
of({ type: "linesDone" })
)
},
{ processResults: true }
https://gist.github.com/deanius/5aba8edf0f102a6269dfbf66a325e96b