Wow, this looks great! 😍
I'm having trouble understanding how the Reader monad can help in more complex examples though.
Take a look at this for instance: (functions with the "2" suffix are the ones that I would write having dependencies as the first parameter)
f needs to make b explicit even if could be implicit (like it is in f2)
all the functions in the g pipe need to take the result from the previous computation and pass it as the first parameter to the transform functions, while this is implicit in g2. This leads to less readable code and harder composition. Is there something I'm missing?
Is it generally right to merge all the dependencies of the functions used by g like I did with Dependencies & OtherDependencies?
Wow, this looks great! 😍
I'm having trouble understanding how the Reader monad can help in more complex examples though.
Take a look at this for instance: (functions with the "2" suffix are the ones that I would write having dependencies as the first parameter)
In particular, notice how:
fneeds to makebexplicit even if could be implicit (like it is inf2)gpipe need to take the result from the previous computation and pass it as the first parameter to the transform functions, while this is implicit ing2. This leads to less readable code and harder composition. Is there something I'm missing?glike I did withDependencies & OtherDependencies?That's exactly what I needed. I saw you just released
chainWin 2.6.0. Great job thanks! :)