Skip to content
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

[docs] Fix base API redirects #36833

Merged
merged 2 commits into from
Apr 11, 2023
Merged

Conversation

mnajdova
Copy link
Member

Resolves #35938 (comment)

@mnajdova mnajdova added bug 🐛 Something doesn't work docs Improvements or additions to the documentation labels Apr 10, 2023
@mui-bot
Copy link

mui-bot commented Apr 10, 2023

Netlify deploy preview

https://deploy-preview-36833--material-ui.netlify.app/

Bundle size report

No bundle size changes

Generated by 🚫 dangerJS against 11df39e

/api/input-unstyled/ /base/api/input-unstyled/ 301
/pt/api/input-unstyled/ /pt/base/api/input-unstyled/ 301
/zh/api/input-unstyled/ /zh/base/api/input-unstyled/ 301
/api/input-unstyled/ /base/react-input/components-api/#input-unstyled 301
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

To avoid double redirects.

/pt/api/modal-unstyled/ /pt/base/api/modal-unstyled/ 301
/zh/api/modal-unstyled/ /zh/base/api/modal-unstyled/ 301
/api/option-group-unstyled/ /base/api/option-group-unstyled/ 301
/:lang/api/option-group-unstyled/ /:lang/base/api/option-group-unstyled/ 301
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Using /:lang/ also matches urls starting with /base/, which causes links like: https://mui.com/base/api/tabs-list-unstyled/ to be broken.

@mnajdova
Copy link
Member Author

@oliviertassinari is there a way of testing the new redirects on pull requests?

@mnajdova mnajdova marked this pull request as ready for review April 10, 2023 11:22
@hbjORbj hbjORbj merged commit e05f16c into mui:master Apr 11, 2023
5 checks passed
@oliviertassinari
Copy link
Member

oliviertassinari commented Apr 14, 2023

Is there a way of testing the new redirects on pull requests?

@mnajdova with Netlify preview.

@oliviertassinari
Copy link
Member

I found a few more double redirections searching for /base/api/ as the destination in the redirections, fixed in https://github.com/mui/material-ui/pull/36969/files#r1174565539.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug 🐛 Something doesn't work docs Improvements or additions to the documentation
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

5 participants