generated from json-schema-org/repo-template
-
-
Notifications
You must be signed in to change notification settings - Fork 16
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
05c9a56
commit 2e51e7c
Showing
4 changed files
with
24 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
import { contentManager } from "@/lib/contentManager"; | ||
import React from "react"; | ||
|
||
export default function Content({ params }: { params: { path: string[] } }) { | ||
const { Page } = contentManager.parseMdxFile(params.path.join("/") + ".mdx"); | ||
return <Page />; | ||
} | ||
export async function generateStaticParams() { | ||
const outline = contentManager.outline; | ||
const pathList: { path: string[] }[] = []; | ||
|
||
outline.map((item) => { | ||
item.steps.map((step) => { | ||
pathList.push({ | ||
path: [item.folderName, step.fileName.replaceAll(".mdx", "")], | ||
}); | ||
}); | ||
}); | ||
console.log(pathList); | ||
return pathList; | ||
} |
File renamed without changes.
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters