4 ms·
What about re-frame is "a mess"? Pretty tiny API surface, solely aimed at forcing the best practices of unidirectional data flow / single source of truth. Have
by pandeiro 10y ago
What about re-frame is "a mess"? Pretty tiny API surface, solely aimed at forcing the best practices of unidirectional data flow / single source of truth. Have you ever looked at what the same thing entails in JavaScript, ie Redux?
- thom 10y agoI'd be happy to concede that my real-life experience of re-frame isn't representative, if someone were to show me an example of best practise. My main worry working on real apps has been that it's very hard to layer subscribe/dispatch in a way that allows for modular components, while at the same time separating out component instance state and app state. Beyond that, the new reg-effect-fx system isn't particularly mature, individual fx aren't extensible, e.g. being able to extend http-fx to cancel or debounce requests. I don't _hate_ it, I'm building apps in it. I just think there's a lot of overhead above Reagent that I have yet to see pay off, and the idea that it _forces_ best practises is wrong. It's like an MVC system that lets you put (_encourages_ you to, if you read the docs) controller code anywhere.
- pandeiro 10y agoKnowing where to use `subscribe` (vs pure components) is an art and something that gets easier/clearer as you understand the app better. I'm happy to take responsibility for that aspect of the architecture though; the library's role is to provide the operations and patterns I might want. And if further generalizable patterns evolve, those can be turned into a higher level library.