3 ms·
Does Mithril include state management? I see it’s being compared to Vue + VueX but I didn’t see other mentions of state management on the linked page.
by IgorPartola 6y ago
Does Mithril include state management? I see it’s being compared to Vue + VueX but I didn’t see other mentions of state management on the linked page.
- christophilus 6y agoIt’s left up to you. POJOs work just fine in Mithril, but you can use any of the existing libraries (Redux, Mobx, etc) too if you want.
- IgorPartola 6y agoSo then it’s probably more fair to compare it to Vue without VueX included, no?
- turblety 6y agoI've only just learned about Mithril streams: https://mithril.js.org/stream.html#combining-streams https://mithril.js.org/stream.html#combining-streams No experience of using them, but they look cool for managing state.
- keb_ 6y agoI wrote a brief blog post[1] about vanilla state management in Mithril. Since Mithril triggers redraws on event handler calls, as another user said, you can just use POJOs very easily. [1] https://kevinfiol.com/blog/simple-state-management-in-mithriljs/ https://kevinfiol.com/blog/simple-state-management-in-mithri...
- NetOpWibby 6y agoYou have a very nice-looking blog.
- keb_ 6y agoThanks!