fix(inertia): make useRoute().fullPath reactive across navigations#256
Merged
Conversation
Port of upstream nuxt/ui c256997 (#6696). The Inertia useRoute() stub returned `fullPath: page.url` — captured once at call time and stale across navigations. Convert it to a getter so reads always reflect the current page.url. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01JS8ypVfQSFzYVZzkTHhURb
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.
Upstream
c256997—fix(inertia): make useRoute().fullPath reactive across navigations (#6696)Change — direct 1:1
The Inertia
useRoute()stub returnedfullPath: page.url— a value captured once at call time, so it went stale across Inertia navigations. Convert it to a getter (get fullPath() { return page.url }) so reads always reflect the currentpage.url. b24ui'ssrc/runtime/vue/stubs/inertia.tsmatched upstream.Tests
Runtime stub → no snapshot churn. Full suite unchanged (5289 passed / 6 skipped).
Verify (CI=true)
dev:prepare·lint·typecheck·test·build— all green.Ledger
.sync/log/c256997….md— port rationale.sync/nuxt-ui.json— addc256997asport, advance cursor; reconcile prior7bdcb13→ PR feat(Prompt): add claude action #255 /9267e867.🤖 Generated with Claude Code
Generated by Claude Code