Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

[release/10.0] Fix fetch request in data-enhance-nav="false" for same-page anchors#63915

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 ourterms of service andprivacy statement. We’ll occasionally send you account related emails.

Already on GitHub?Sign in to your account

Merged
wtgodbe merged 5 commits intorelease/10.0frombackport/pr-63449-to-release/10.0
Oct 3, 2025

Conversation

@github-actions
Copy link
Contributor

@github-actionsgithub-actionsbot commentedOct 3, 2025
edited by ilonatommy
Loading

Backport of#63449 to release/10.0

/cc@ilonatommy@dariatiurina

Fix fetch request in data-enhance-nav="false" for same-page anchors

Fixes#55534.

Description

This pull request enhances the navigation logic to better handle hash-only changes in URLs, ensuring that navigation to anchors within the same page does not trigger a full page reload or unnecessary fetch requests. It introduces a utility function to detect hash-only changes and updates the navigation handler to leverage this, improving performance and user experience. Additional end-to-end tests and markup updates verify and demonstrate the new behavior.

Changes:

  • Added theisHashOnlyChange utility function inNavigationUtils.ts to detect when a navigation event only changes the hash fragment, avoiding unnecessary page loads.
  • Updated theonPopState handler inNavigationEnhancement.ts to useisHashOnlyChange, preventing enhanced navigation logic from running when only the hash changes.
  • Added a new end-to-end test inEnhancedNavigationTest.cs to verify that non-enhanced navigation to a hash does not trigger a page fetch, ensuring the scroll behavior works as expected without unnecessary network activity.

Customer Impact

In the special cases for the same-page hash navigation without this bug fix the infinite cycle can occur. This prevents it. The fix is localized to the enhanced navigation.

Regression?

  • Yes
  • No

Risk

  • High
  • Medium
  • Low

The fix is limited to same-page navigation on elements that have enhanced navigation explicitly disabled.

Verification

  • Manual (required)
  • Automated

Packaging changes reviewed?

  • Yes
  • No
  • N/A

@lewinglewing added Servicing-approvedShiproom has approved the issue and removed Servicing-considerShiproom approval is required for the issue labelsOct 3, 2025
@lewing
Copy link
Member

approved in email

@wtgodbewtgodbe merged commit89f8531 intorelease/10.0Oct 3, 2025
28 checks passed
@wtgodbewtgodbe deleted the backport/pr-63449-to-release/10.0 branchOctober 3, 2025 16:10
@dotnet-policy-servicedotnet-policy-servicebot modified the milestone:10.0.0Oct 3, 2025
wtgodbe added a commit that referenced this pull requestOct 3, 2025
….0 (#63920)[release/10.0] Fix fetch request in data-enhance-nav="false" for same-page anchorsCo-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
Sign up for freeto join this conversation on GitHub. Already have an account?Sign in to comment

Reviewers

@lewinglewinglewing approved these changes

Assignees

@dariatiurinadariatiurina

Labels

area-blazorIncludes: Blazor, Razor ComponentsServicing-approvedShiproom has approved the issue

Projects

None yet

Milestone

10.0.0

Development

Successfully merging this pull request may close these issues.

5 participants

@lewing@wtgodbe@ilonatommy@dariatiurina

[8]ページ先頭

©2009-2025 Movatter.jp