(Code on Github : Flux.Net)
These days, I took some time to learn facebook’s React and like everyone, came across their Flux Pattern. if I can resume or take one sentence that seemed to be important is this idea:
Flux is used to have a more predictable system.
When looking at the pattern, and trying their Todo or Chat apps, it is not really clear where the call to the server occurs or at least it’s not yet standardized.(as far as I know).
Flux is stated to be a frontend framework, but wait, why would this pattern be more obvious as a frontend pattern.
So, just for learning purposes, and hopefully to start a good in depth discussion arround it, I started a c# implementation of flux to understand the bits and pieces and where they should fit in.
If you would like to start the discussion, check the code here : Flux.Net
You can clone the project and go to each Tag to see evolution of the code or simply download each release.
Just start the Flux.Net.Cmd project. But I tell you, it’s a Naive and BASIC implementation. (and perhaps with some errors regarding the pattern)
In this iteration, I made some code refactoring just to implement something more closer to the Chat application that facebook presents.
This release puts SignalR in the Mix. I will use SignalR to notify clients of changes in the store. The store is on the backend… and here the clients runs in a browser… (a kind of a mix of SignalR chat demo app and Facebook’s Flux Chap application…)
- create some kind of generic implementation
- put React in the mix where a component would listen to the Store changes (store located on the server)
This will be part of a new Post…and before it, I Hope to start a good discussion on this implementation.