Skip to content

[Blazor] Improvements to how SSR'd components are activated for interactivity #50849

Closed
@MackinnonBuck

Description

@MackinnonBuck

1. An SSR update can no longer supply new parameters to an existing component. Instead, the component will be disposed and re-initialized unless its parameters definitely have not changed.

It's the client's choice to decide which components receive which parameters from an SSR update. The implementation in blazor.web.js does this by guessing "visually" whether an SSR component correlates to an existing component on the page. However, this could lead to undesirable behavior and open up the opportunity for malicious clients to abuse this behavior.

2. After each batch of root component updates, the number of active Blazor Server components may not exceed the number of components rendered with the "auto" or "server" render modes in the last SSR update (prototyped, not yet in this PR).

This prevents clients from holding onto Blazor Server components indefinitely, causing unwanted strain on the server.

Metadata

Metadata

Assignees

Labels

area-blazorIncludes: Blazor, Razor ComponentsbugThis issue describes a behavior which is not expected - a bug.

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions