4 ms·
It's an answer to the question of "how do I manage state in SPA?" It is similar to redux, but: * waaay less boilerplate * very neat concept of "reactive subsc
by lambdadmitry 10y ago
It's an answer to the question of "how do I manage state in SPA?" It is similar to redux, but:
* waaay less boilerplate
* very neat concept of "reactive subscriptions network", which is a way to minimize re-renderings. Let's say you have keys "items", "sortOrder" and "mouseX" in your storage; how do you avoid rerendering your components each time user moves their pointer? Moreover, let's say you have a list of "items" that is sorted in "sortOrder". How do you avoid re-sorting? Re-frame allows you to skip updates entirely, neatly minimizing change propagation and avoiding React re-rendering in most cases.
* there is a sane story around complex async processing, namely [1]. It's similar in purpose to redux-saga, but simpler, more explicit, debuggable and compatible with time-travel and everything.
[1]: https://github.com/Day8/re-frame-async-flow-fx https://github.com/Day8/re-frame-async-flow-fx