fix: update docs addon link on homepage to resolve 404#426
Open
algojogacor wants to merge 1 commit into
Open
Conversation
👷 Deploy request for storybook-frontpage pending review.Visit the deploys page to approve it
|
👷 Deploy request for storybook-addon-catalog pending review.Visit the deploys page to approve it
|
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.
Summary
Fixes #422 — the "Learn about docs addon" button on the Storybook homepage links to
/docs/writing-docs/introductionwhich returns a 404. Updated to link to/docs/writing-docswhich is the canonical URL (a 301 redirect from the old path is already configured).Root Cause
The
document.tsxcomponent on the homepage contains a hardcoded link to/docs/writing-docs/introduction. While a 301 redirect exists inraw-redirectsto forward this path to/docs/writing-docs, the redirect doesn't prevent users from seeing a 404 when the redirect chain breaks.Solution
Updated the
hrefin the "Learn about docs addon" feature link from/docs/writing-docs/introductionto/docs/writing-docs— the canonical path already defined as the redirect target.Changes
apps/frontpage/components/home/document/document.tsx: Changed href from/docs/writing-docs/introductionto/docs/writing-docs(+1 -1)Testing
/docs/writing-docspath/docs/writing-docs/introductionin the codebase