Replies: 4 comments
-
Please check the documentation at https://github.com/mrpmorris/Fluxor/tree/master/Source/Tutorials/02-Blazor/02A-StateActionsReducersTutorial The page/component does automatically trigger a re-render on state update if the page/component inherits from FluxorComponent as described in the above docs. |
Beta Was this translation helpful? Give feedback.
-
That is the problem I am having, It does not seem to be re-rendering on state changed.
Then I tried the other approach....
Neither causes the page to re-render when state is changed due to calling that async Effect action. https://learn.microsoft.com/en-us/aspnet/core/blazor/components/lifecycle?view=aspnetcore-8.0 I am wondering if it is because its an action to and async Effect, but do not see why that would be an issue. |
Beta Was this translation helpful? Give feedback.
-
Can you create a minimal repro? |
Beta Was this translation helpful? Give feedback.
-
@mrpmorris P.S. :I have been experimenting over the last days, and realize that it is what I want to do that is at issue here, and that I am in need of a pattern to solve it. Some context:
If I refresh (or visit for the first time) the page I had wanted to see the information in the form, and likewise, if I navigate to and back. As it is now if you refresh the page, it is stuck on loading. State due to being fetched is updating too late to be put into forecasts. There is what I call a hacky fix to get the desired result where forecasts is set only in |
Beta Was this translation helpful? Give feedback.
-
Need some assistance.
I am sending an Effects action in
OnInitialized
.The effect calls and api and eventually retrieves that data and sets state.
I've injected the state that is eventually updated on the page, however when that piece of state is eventually updated the page is not re-rendering.
My hope was that when that state changed the page would detect it and re-reneder via the fluxor plumbing.
Is there a pattern for this that works?
Beta Was this translation helpful? Give feedback.
All reactions