luminus

adc17 2019-03-03T01:11:55.019800Z

@yogthos so component vs mount is kind of 'dependency inversion' vs 'no dependencies'? This makes a lot of sense, but it's hard! Not being able to pass impure functions into your business logic (e.g. find and save) makes finding abstractions that don't significantly reduce the ratio of business logic/IO trickier, at least for me. Would you recommend any patterns/thought processes/examples that help with this?

adc17 2019-03-05T11:28:21.022300Z

thanks, will give that a try

yogthos 2019-03-03T01:37:46.020500Z

one thing that might help is to start with the business logic and to mock out the data you're expecting from external sources

yogthos 2019-03-03T01:38:40.020700Z

so you'd create a mock API that you get data from, and then work against that, and then you couple it to the actual IO afterwards

yogthos 2019-03-03T01:41:09.020900Z

ah ok, yeah selmer doesn't really provide support for that, I find it's usually better to massage data before you pass it to selmer

yogthos 2019-03-03T01:41:42.021100Z

so for example you could do group-by and then do an if for each category in selmer

jumar 2019-03-03T07:36:41.021300Z

Great, thanks for the response. I wasn't really sure what's possible and what not.