-
-
Notifications
You must be signed in to change notification settings - Fork 1.4k
Correct NextJS link URL #5488
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 our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Merged
Correct NextJS link URL #5488
Changes from 1 commit
Commits
Show all changes
2 commits
Select commit
Hold shift + click to select a range
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
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
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.
Uh oh!
There was an error while loading. Please reload this page.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Broken relative path to Next.js migration guide
Using
../migrate-from-next-jsclimbs out of thereact/directory, landing on a non-existentframework/migrate-from-next-jspage. Switch to the local./migrate-from-next-jspath so the link resolves toframework/react/migrate-from-next-js.📝 Committable suggestion
🧰 Tools
🪛 LanguageTool
[grammar] ~10-~10: There might be a mistake here.
Context: ...or your specific framework: - Next.js - Remix 2 / React Router 7 "Framework Mode...
(QB_NEW_EN)
🤖 Prompt for AI Agents
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This and the other link change follow the precedent in the file of links that work properly. I'm not close enough to the project to know why they're all beginning with
../.Would be interested to learn if there's an easy explanation 🙂
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🧩 Analysis chain
🏁 Script executed:
Length of output: 2032
🏁 Script executed:
Length of output: 1634
🏁 Script executed:
Length of output: 29100
@aaronjordan Great question! 🙂
The
../pattern works here because TanStack uses a custom documentation framework that handles link resolution differently from standard filesystem relative paths. Looking at thedocs/start/config.jsonfile, I can see how the routing structure is defined.Here's what's happening:
From the file system perspective:
docs/start/framework/react/getting-started.md../quick-startwould normally resolve todocs/start/framework/quick-start.md(which doesn't exist!)But from the documentation framework's perspective:
config.jsonwhere routes are defined as:"to": "framework/react/getting-started""to": "framework/react/quick-start""to": "framework/react/migrate-from-next-js"How the framework resolves
../links:The documentation build system treats
../as a special prefix that gets intelligently resolved against the routing structure. When you're on a page atframework/react/getting-startedand use:../quick-start→ resolves toframework/react/quick-start../guide/routing→ resolves toframework/react/guide/routing../migrate-from-next-js→ resolves toframework/react/migrate-from-next-jsThis is why your change from
../guide/migrate-from-next-jsto../migrate-from-next-jsis correct—it matches the actual route structure defined in the config, where the migration guide is atframework/react/migrate-from-next-js, notframework/react/guide/migrate-from-next-js.The
../prefix is essentially a convention used by the TanStack docs framework to indicate "resolve this relative to the current page's context" rather than performing literal directory traversal.