mirror of
https://github.com/facebook/docusaurus.git
synced 2025-12-26 01:33:02 +00:00
remove useless comments
This commit is contained in:
parent
362573a391
commit
4913ca638e
|
|
@ -79,44 +79,11 @@ function createRoutePathRedirects(
|
|||
routePath: string,
|
||||
redirectCreator: RedirectsCreator,
|
||||
): RedirectMetadata[] {
|
||||
/*
|
||||
// TODO do we receive absolute urls???
|
||||
if (!path.isAbsolute(routePath)) {
|
||||
return [];
|
||||
}
|
||||
|
||||
*/
|
||||
|
||||
/*
|
||||
// TODO addTrailingSlash ?
|
||||
const toUrl = addTrailingSlash(`${baseUrl}${routePath}`);
|
||||
|
||||
const redirectPageContent = createRedirectPageContent({toUrl});
|
||||
|
||||
*/
|
||||
|
||||
const fromRoutePaths: string[] = redirectCreator(routePath) ?? [];
|
||||
|
||||
return fromRoutePaths.map((fromRoutePath) => {
|
||||
return {
|
||||
fromRoutePath,
|
||||
toRoutePath: routePath,
|
||||
};
|
||||
});
|
||||
/*
|
||||
return fromRoutePaths.map((fromRoutePath) => {
|
||||
const redirectAbsoluteFilePath = path.join(
|
||||
outDir,
|
||||
getFilePathForRoutePath(fromRoutePath),
|
||||
);
|
||||
return {
|
||||
fromRoutePath,
|
||||
toRoutePath: routePath,
|
||||
toUrl,
|
||||
redirectPageContent,
|
||||
redirectAbsoluteFilePath,
|
||||
};
|
||||
});
|
||||
|
||||
*/
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in New Issue