Skip to content

Commit be37fe3

Browse files
committed
wiki static page route 문제 해결
1 parent df5df87 commit be37fe3

File tree

7 files changed

+40
-30
lines changed

7 files changed

+40
-30
lines changed

app/wiki/[...slug]/page.tsx

Lines changed: 1 addition & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,17 +1,11 @@
11
import { getAllStaticPaths, getMDXContent } from '@/lib/static-page';
22
import { MDXRemote } from 'next-mdx-remote/rsc';
33

4-
/**
5-
* Next.js가 빌드 시점에 이 함수를 실행하여,
6-
* 어떤 정적 페이지들을 미리 생성해야 할지 목록을 받아갑니다.
7-
* 최종 반환값 예시: [{ slug: ['style', 'classic'] }, { slug: ['material', 'denim'] }]
8-
*/
9-
104
export async function generateStaticParams() {
115
return getAllStaticPaths('content/wiki');
126
}
137

14-
export default async function WikiPage({ params }: { params: { slug: string[] } }) {
8+
export default async function WikiPage({ params }: any) {
159
const { content, frontmatter } = getMDXContent('content/wiki', params.slug);
1610

1711
return (
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.

public/wiki-data.json

Lines changed: 39 additions & 23 deletions
Large diffs are not rendered by default.

0 commit comments

Comments
 (0)