coblox / bobtimus

an autobot that automatically handles swaps as Bob
Apache License 2.0
1 stars 1 forks source link

Optimize RxJS composition + better logging #8

Closed thomaseizinger closed 5 years ago

thomaseizinger commented 5 years ago

Currently, we just log the result after we selected an action and then unwrap it:

https://github.com/coblox/bobtimus/blob/4d030cdcbba4ccd7cfd200f28236453a6a1ed173/src/index.ts#L16-L18

It would be better if we would unpack (think match) the result and log different messages based on the result. A flatMap kind of operation should allow us to do this within one pipe call to make the whole thing less awkward.

bonomat commented 5 years ago

Closed as we do not use RxJS in bobtimus anymore.