Skip to content

Blazor 8 PersistentComponentState and Enhanced Navigation #51610

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
1 task done
oliverw opened this issue Oct 24, 2023 · 2 comments
Closed
1 task done

Blazor 8 PersistentComponentState and Enhanced Navigation #51610

oliverw opened this issue Oct 24, 2023 · 2 comments
Labels
area-blazor Includes: Blazor, Razor Components

Comments

@oliverw
Copy link

oliverw commented Oct 24, 2023

Is there an existing issue for this?

  • I have searched the existing issues

Describe the bug

I have noticed that when navigating inside a Blazor 8 Web App, components using @rendermode InteractiveAuto are rendered once on the server during pre-rendering at which point I store the state in PersistentComponentState. When the component is rendered the second time on the client, the state is not available forcing the client to load the data a second time using a http request. Is this working as intended? Sounds like a waste of computation resources.

Expected Behavior

No response

Steps To Reproduce

No response

Exceptions (if any)

No response

.NET Version

8.0.100-rc.2.23502.2

Anything else?

No response

@ghost ghost added the area-blazor Includes: Blazor, Razor Components label Oct 24, 2023
@MackinnonBuck
Copy link
Member

Thanks for filing the issue, @oliverw!

The current mechanism for persistent component state only allows reading persisted state after the initial page load. This currently excludes enhanced navigations, but we have #51584 to track having better support for the enhanced navigation scenario.

I'm going to close this out as a duplicate of the existing issue. Thanks again 🙂

@MackinnonBuck MackinnonBuck closed this as not planned Won't fix, can't repro, duplicate, stale Oct 24, 2023
@Markz878
Copy link

Markz878 commented Oct 26, 2023

@MackinnonBuck @danroth27: Really worrying that people who are stuck on LTS releases will have to deal with this performance issue for 2 years if this is not fixed.

@ghost ghost locked as resolved and limited conversation to collaborators Nov 25, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
area-blazor Includes: Blazor, Razor Components
Projects
None yet
Development

No branches or pull requests

3 participants