Skip to content

Blazor NavigationManager.NavigateTo always scrolls page to the top. #40190

@groogiam

Description

@groogiam

Is there an existing issue for this?

  • I have searched the existing issues

Describe the bug

It appears the navigation manger in .NET 6 always scrolls the page to the top even if NavigateTo call is just updating the query string.

Expected Behavior

Navigations that do not change the page should not reset the viewport position.

Steps To Reproduce

Will post a repro shortly.

Exceptions (if any)

No response

.NET Version

6.0.102

Anything else?

No response

Metadata

Metadata

Assignees

Labels

Pillar: Technical DebtPriority:1Work that is critical for the release, but we could probably ship withoutarea-blazorIncludes: Blazor, Razor ComponentsenhancementThis issue represents an ask for new feature or an enhancement to an existing onefeature-blazor-routingFeatures related to routing in Blazor applicationstriaged

Type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions