An easier alternative is to wrap the value into an array, then use `.map()` for each function in the chain, and finally escape the value with `[0]`
I made a similar data structure[1] to allow adding side effect (no return value) as part of the chained function.
[1] https://github.com/beenotung/tslib/blob/9f9a9274c1e13be7ba83...