We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
2 parents efc44c0 + 0c27720 commit 76c72f1Copy full SHA for 76c72f1
src/routes/index.ts
@@ -91,7 +91,8 @@ export default function generateRoutes() {
91
routes.source[name] = routeUsefulPath;
92
routes.routeMap[name] = `/${routeUsefulPath}`;
93
const shortLink = name.replace(/([A-Z])/g, "-$1").toLowerCase();
94
- routes.customRoutes[`/${routeUsefulPath}`] = `/${shortLink}`;
+ routes.customRoutes[`/${routeUsefulPath}`] =
95
+ `/${shortLink.startsWith('-') ? shortLink.slice(1) : shortLink}`;
96
routes.names.push(name);
97
routes.pages = moveHomeToFirst(routes.pages)
98
}
0 commit comments