diff --git a/app-links.js b/app-links.js index 1c2b61ca..39e31f06 100644 --- a/app-links.js +++ b/app-links.js @@ -90,15 +90,15 @@ export const appLinks = [ }, { from: '/app-links/auto-space-detection', - to: '/docs/editing-text/#auto-space-detection', + to: '/docs/editing-text#auto-space-detection', }, { from: '/app-links/html-lint', - to: '/docs/Features/Problems Panel/html-lint/', + to: '/docs/Features/Problems Panel/html-lint', }, { from: '/app-links/ESLint', - to: '/docs/Features/Problems Panel/ESLint/', + to: '/docs/Features/Problems Panel/ESLint', }, { from: '/app-links/live-preview-settings', @@ -106,11 +106,11 @@ export const appLinks = [ }, { from: '/app-links/editor-rulers', - to: '/docs/Features/editor-rulers/', + to: '/docs/Features/editor-rulers', }, { from: '/app-links/find-in-files', - to: '/docs/Features/find-in-files/', + to: '/docs/Features/find-in-files', }, { from: '/app-links/custom-snippets', diff --git a/docusaurus.config.js b/docusaurus.config.js index dfa2e7f8..0d54856f 100644 --- a/docusaurus.config.js +++ b/docusaurus.config.js @@ -157,7 +157,17 @@ const config = { [ "@docusaurus/plugin-client-redirects", { - redirects: appLinks, + redirects: [ + ...appLinks, + { from: '/docs/Features/recent-files', to: '/docs/file-management#recent-files' }, + { from: '/docs/Features/live-preview-settings', to: '/docs/Features/Live Preview/live-preview-settings' }, + ], + createRedirects(existingPath) { + if (existingPath !== '/') { + return [existingPath + '/']; + } + return []; + }, } ] ],