Our great sponsors
-
The Flux pattern is distinguished by its unidirectional flow of changes to a Store that holds the application State, mediated by a Dispatcher that directs dispatched Actions to the appropriate Store functions (Reducers and Effects) that manage the State in a controlled manner.
-
Is it possible to use the Flux pattern with Blazor? Sure it is. There are a couple of libraries that have been written to implement Flux in .NET, and the one that seems to have the most traction and which I have enjoyed using is Fluxor, by Peter Morris.
-
SurveyJS
Open-Source JSON Form Builder to Create Dynamic Forms Right in Your App. With SurveyJS form UI libraries, you can build and style forms in a fully-integrated drag & drop form builder, render them in your JS app, and store form submission data in any backend, inc. PHP, ASP.NET Core, and Node.js.
-
If you are new to Fluxor, or to the Flux/Redux approach in general then this YouTube video by Nick Chapsas is an excellent introduction The video is based on the original Blazor-Fluxor library, but the concepts are the same.
-
But, since Blazor is essentially a SPA, it's useful to consider how other SPA frameworks manage state. For instance, how does React do it? As it turns out, there are a lot of state management libraries that can be used with React, but one of the original (and still most commonly used) libraries is Redux.