This is an automated email from the ASF dual-hosted git repository.
leonard pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/fluss.git
The following commit(s) were added to refs/heads/main by this push:
new 1c6c72213 [FLUSS-2062][docs] Added Redirect for Latest Stable Version
Docs (#2085)
1c6c72213 is described below
commit 1c6c7221399af539bfb70164aa2dbd113491fc7f
Author: Rion Williams <[email protected]>
AuthorDate: Wed Dec 3 02:42:28 2025 -0600
[FLUSS-2062][docs] Added Redirect for Latest Stable Version Docs (#2085)
This closes #2085.
---
website/docusaurus.config.ts | 26 ++++++++++++++++++++++++++
website/package.json | 1 +
2 files changed, 27 insertions(+)
diff --git a/website/docusaurus.config.ts b/website/docusaurus.config.ts
index 2edc586f4..7e8a99430 100644
--- a/website/docusaurus.config.ts
+++ b/website/docusaurus.config.ts
@@ -124,6 +124,32 @@ const config: Config = {
],
},
],
+ [
+ '@docusaurus/plugin-client-redirects',
+ {
+ // Create redirects from the available routes that have already been
created
+ createRedirects(existingPath) {
+ // Only evaluate paths related to documentation
+ if (!existingPath.startsWith('/docs/')) {
+ return undefined;
+ }
+
+ // Extract the relative path after /docs/
+ const relativeDocsPath = existingPath.substring(6);
+ const firstSegment = relativeDocsPath.split('/')[0];
+
+ // Exclude any known version identifiers aligned with existing
routes
+ const existingVersionedRoutes = ['next',
...Object.keys(versionsMap)];
+ if (existingVersionedRoutes.includes(firstSegment)) {
+ return undefined;
+ }
+
+ // Redirect the explicit versioned path to the implicit
unversioned path
+ return [`/docs/${latestVersion}${existingPath.replace('/docs',
'')}`];
+ },
+ },
+ ],
+
],
themeConfig: {
image: 'img/logo/png/colored_logo.png',
diff --git a/website/package.json b/website/package.json
index 344480e0a..c17363c78 100644
--- a/website/package.json
+++ b/website/package.json
@@ -17,6 +17,7 @@
"dependencies": {
"@docusaurus/core": "^3.9.2",
"@docusaurus/plugin-pwa": "^3.9.2",
+ "@docusaurus/plugin-client-redirects": "^3.9.2",
"@docusaurus/preset-classic": "^3.9.2",
"@mdx-js/react": "^3.0.0",
"algoliasearch": "^5.10.2",