-
Notifications
You must be signed in to change notification settings - Fork 0
/
next.config.mjs
34 lines (32 loc) · 1019 Bytes
/
next.config.mjs
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
import withMDX from "@next/mdx";
import rehypeKatex from "rehype-katex";
import remarkMath from "remark-math";
import remarkFrontmatter from "remark-frontmatter";
import remarkMdxFrontmatter from "remark-mdx-frontmatter";
import rehypePrettyCode from "rehype-pretty-code";
import rehypeSlug from "rehype-slug";
import rehypeAutolinkHeadings from "rehype-autolink-headings";
import remarkToc from "remark-toc";
/** @type {import('next').NextConfig} */
const nextConfig = {
pageExtensions: ["js", "jsx", "mdx", "ts", "tsx"],
output: "export",
images: { unoptimized: true },
};
export default withMDX({
options: {
rehypePlugins: [
rehypeKatex,
rehypePrettyCode,
rehypeSlug,
[rehypeAutolinkHeadings, { behavior: "append" }],
],
remarkPlugins: [
remarkMath,
remarkFrontmatter,
[remarkMdxFrontmatter, { name: "metadata" }],
[remarkToc, { heading: "(table[ -]of[ -])?contents?|toc|목차" }],
],
experimental: { mdxRs: true },
},
})(nextConfig);