dotnet / aspnetcore

ASP.NET Core is a cross-platform .NET framework for building modern cloud-based web applications on Windows, Mac, or Linux.
https://asp.net
MIT License
35.44k stars 10.03k forks source link

Synchronize the state of RenderModeWebAssembly and RenderModeServer #50966

Open Alerinos opened 1 year ago

Alerinos commented 1 year ago

Is there an existing issue for this?

Is your feature request related to a problem? Please describe the problem.

I have many different components. For example, the navigation is in wasm, in the navigation I have a button to change the language of the page. When you press it, it changes the language from English to Polish. I would like to transfer it now to the state of SSR Blazor. How can I do this? Currently the state is separate in SSR and WASM. It would be useful to be able to designate the transfer of state between them.

Describe the solution you'd like

I would like to transfer the state from WASM to Server Side Blazor. If I click something in the WASM navigation then in Server Side Blazor it will execute event Action StateHasChanged.

ghost commented 1 year ago

Thanks for contacting us.

We're moving this issue to the .NET 9 Planning milestone for future evaluation / consideration. We would like to keep this around to collect more feedback, which can help us with prioritizing this work. We will re-evaluate this issue, during our next planning meeting(s). If we later determine, that the issue has no community involvement, or it's very rare and low-impact issue, we will close it - so that the team can focus on more important and high impact issues. To learn more about what to expect next and how this issue will be handled you can read more about our triage process here.

ghost commented 10 months ago

Thanks for contacting us.

We're moving this issue to the .NET 9 Planning milestone for future evaluation / consideration. We would like to keep this around to collect more feedback, which can help us with prioritizing this work. We will re-evaluate this issue, during our next planning meeting(s). If we later determine, that the issue has no community involvement, or it's very rare and low-impact issue, we will close it - so that the team can focus on more important and high impact issues. To learn more about what to expect next and how this issue will be handled you can read more about our triage process here.

ghost commented 9 months ago

We've moved this issue to the Backlog milestone. This means that it is not going to be worked on for the coming release. We will reassess the backlog following the current release and consider this item at that time. To learn more about our issue management process and to have better expectation regarding different types of issues you can read our Triage Process.

danroth27 commented 9 months ago

I would like to transfer the state from WASM to Server Side Blazor.

@Alerinos Would this just be an API call to a server endpoint to transfer whatever state you want? How would Blazor be involved here?

Alerinos commented 9 months ago

@danroth27 I don't know if I remember correctly, but I think I was referring to the possibility of integration in the Scope server side. The idea is that if we change something in the client o it will communicate with the server and change its state.

For example: We have a navigation component (client), there is a list of languages in it. We want to change the language, scope in the client will change it for us, but the server does not see it. The server has its scope. We can't do it through REST or Socket API because then we would have to make a separate session which would have to be kept somewhere, then we would have to execute an event which would change the Scope in SSR.