Repository navigation
fix: respect replaceState/keepFocus/noScroll when a navigation results in a redirect - #14424
Merged
Merged
Conversation
This reverts commit 481e1ab.
…irect while invalidating
🦋 Changeset detectedLatest commit: 5ffc846 The changes in this PR will be included in the next version bump. This PR includes changesets to release 1 package
Not sure what this means? Click here to learn what changesets are. Click here if you're a maintainer who wants to add another changeset to this PR |
replaceState/keepFocus/noScroll when a navigation results in a redirect
Merged
|
This happens even with |
Member
Author
|
@FilippoSalvarani21 can you create a new issue? Preferably with a minimal reproduction. |
Copilot AI
pushed a commit
to Stadly/kit
that referenced
this pull request
Mar 6, 2026
…results in a redirect (sveltejs#14424) * respect replace_state on external navigation where applicable * changeset * added tests * fixed client navigation * prettier * changeset * take out trash * take out trash * take out trash * Apply suggestion from @eltigerchino * changeset * fix typo * Apply suggestion from @eltigerchino * Update .changeset/dirty-rats-divide.md * Delete packages/kit/test/apps/basics/src/routes/navigation/nonexistent/.gitkeep * add replaceState to invalidate * fix test * move tests to `goto` suite * change tests according to code review suggestions * take out trash * test fix * fix lint * fix typo * typedef * typedef * fix lint * refactor test * Revert "fix lint" This reverts commit 481e1ab. * remove opts from invalidate/All * always set `replaceState` to `true` when a load function throws a redirect while invalidating * call navigate directly and forward other state as well * sort imports like on main * we don't need an `opts` object on `native_navigation` * revert invalidate in tests * revert invalidate/All types * changelog * 20 --------- Co-authored-by: akonstantinov <akonstantinov@ozon.ru> Co-authored-by: Tee Ming <chewteeming01@gmail.com>
teemingc
added a commit
that referenced
this pull request
Oct 14, 2026
…17440) - Service-worker lookup/update failures escape both deployment-recovery paths and prevent full-document navigation. - Retain the awaited refresh introduced in [#12448](#12448) and documented in [#16310](#16310); deleting or fire-and-forgetting it loses the opportunity to install an updated worker before reloading. - Catch failures in the shared helper rather than individual callers; preserve module-failure recovery ([#8487](#8487)), version gating ([#16496](#16496)), and replacement-history semantics ([#14424](#14424)). - Cover synchronous/rejected lookups, failed updates, missing registrations, and successful-update sequencing in both route-load and error-status recovery. Fixes #17435 <!-- svelte-triage-bot:feedback-baseline:50cc6409e1816477e9f7fd0bb3702a95dc6b5e4f --> --------- Co-authored-by: svelte-triage-bot <team@svelte.com> Co-authored-by: Tee Ming <chewteeming01@gmail.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Fixes #13403
An alternative to #13303 that does not change
invalidate()/invalidateAll()Please don't delete this checklist! Before submitting the PR, please make sure you do the following:
Tests
pnpm testand lint the project withpnpm lintandpnpm checkChangesets
pnpm changesetand following the prompts. Changesets that add features should beminorand those that fix bugs should bepatch. Please prefix changeset messages withfeat:,fix:, orchore:.Edits