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

Add Redirects #553

Merged
merged 2 commits into from
Jan 19, 2024
Merged

Add Redirects #553

merged 2 commits into from
Jan 19, 2024

Conversation

marklundin
Copy link
Member

This PR adds the docusaurus redirects plugin and redirects any path starting in /en to the root. This should help solve existing inbound links which use /en/**/*.

Note this only works in production, not in dev, also it does not cover all situations as there are new routes used in the docusaurus upgrade.

I confirm I have read the contributing guidelines and signed the Contributor License Agreement.

@willeastcott
Copy link
Contributor

willeastcott commented Jan 19, 2024

I've also moved:

/user-manual/designer/* -> /user-manual/editor/*
/user-manual/packs/* -> /user-manual/scenes/*

I'm wondering if we can add redirects for those too?

@marklundin
Copy link
Member Author

Yep, will add these? Are there any others? Also I wonder if we can use this for /api -> api.playcanvas.com

@willeastcott
Copy link
Contributor

The API is a tricky one because we're not only changing the domain, but we're migrating from JSDoc to TypeDoc, which formats the page URLs quite differently. That said, there's probably a pattern we can follow to redirect most links successfully.

@marklundin
Copy link
Member Author

I've added

/en/user-manual/designer/* -> /user-manual/editor/*
/en/user-manual/packs/* -> /user-manual/scenes/*

Left the /api route for now, until we have a subdomain

Copy link
Contributor

@willeastcott willeastcott left a comment

Choose a reason for hiding this comment

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

Nice one!

@marklundin marklundin merged commit d487e3a into dev Jan 19, 2024
@marklundin marklundin deleted the en-redirects branch January 19, 2024 16:24
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants