-
-
Notifications
You must be signed in to change notification settings - Fork 1.7k
Clarify that redirects can only be done at page level #12325
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
Conversation
Lunaria Status Overview🌕 This pull request will trigger status changes. Learn moreBy default, every PR changing files present in the Lunaria configuration's You can change this by adding one of the keywords present in the Tracked Files
Warnings reference
|
✅ Deploy Preview for astro-docs-2 ready!Built without sensitive environment variables
To edit notification comments on pull requests, go to your Netlify project configuration. |
Hello! Thank you for opening your first PR to Astro’s Docs! 🎉 Here’s what will happen next:
|
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.
Hi, thank you for adding this helpful clarification! We have this content in our reference entry for redirect
, so I think that means linking directly there is probably helpful!
I think we can even emphasize the word "page" to get it in people's brains a little more, with an update to the initial sentence, maybe something like:
On the
Astro
global, theAstro.redirect
method allows you to redirect from one page to another page dynamically.
Co-authored-by: Sarah Rainsberger <[email protected]>
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.
Great! Thank you so much for this contribution @mauriciabad ! 🙌
Description (required)
Improving the documentation regarding redirects. It wasn't clear that they must be done at page level withastro/astro#9188 (comment)
Related issues & labels (optional)
Also made this PR to improve the documentation on the error code that happens when a redirect is not done at page level:
withastro/astro#14391