引入 mdx 以显示 markdown 文档,使用 tailwind 默认排版样式;修正 eslint 规则

This commit is contained in:
2025-06-05 17:29:32 +08:00
parent c17c17724f
commit 7fff0308d0
11 changed files with 1358 additions and 7 deletions

View File

@@ -1,7 +1,18 @@
import type { NextConfig } from "next"
import createMDX from "@next/mdx"
import remarkGfm from 'remark-gfm'
const nextConfig: NextConfig = {
output: "standalone",
pageExtensions: ['js', 'jsx', 'md', 'mdx', 'ts', 'tsx'],
}
export default nextConfig
const withMdx = createMDX({
extension: /\.(md|mdx)$/,
options: {
remarkPlugins: [remarkGfm],
rehypePlugins: [],
}
})
export default withMdx(nextConfig)