-
Notifications
You must be signed in to change notification settings - Fork 146
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
fix: langRoutePrefix should end with slash #1539
Conversation
✅ Deploy Preview for aquamarine-blini-95325f ready!
To edit notification comments on pull requests, go to your Netlify site configuration. |
I think we should only modify code here
instead of the public hook of |
@Timeless0911 The default |
I cannot confirm whether the modification of this hook will affect the use in other places and other users who import it at runtime. In addition, personally I think
This should be optimized with rspress/packages/shared/src/runtime-utils/index.ts Lines 235 to 263 in ae1bf88
|
There is a problem that When toggling language, it goes to |
Yes, this is a question that needs to be considered. The situation is different when there is an html suffix or not ( |
Is this really expected? As I mentioned, |
I know what you mean, we should ensure the request is |
I think this PR can be merged for better semantics of link. |
Summary
langRoutePrefix
is used atrspress/packages/theme-default/src/components/Nav/NavBarTitle.tsx
Line 47 in ae1bf88
Without the trailing slash, for located pages, it renders
/zh
for example, which means/zh.html
but it should be/zh/index.html
actually. And this change matches the defaultlangRoutePrefix
(/
).Related Issue
Checklist