feat: add remark-smartypants for typographic improvements
This commit is contained in:
@@ -3,9 +3,12 @@ import { MDXRemote } from 'next-mdx-remote/rsc'
|
||||
import { useMDXComponents } from '@/mdx-components'
|
||||
import remarkMath from 'remark-math'
|
||||
import remarkGfm from 'remark-gfm'
|
||||
import smartypants from 'remark-smartypants'
|
||||
import rehypePrettyCode from 'rehype-pretty-code'
|
||||
import rehypeAutolinkHeadings from 'rehype-autolink-headings'
|
||||
import rehypeKatex from 'rehype-katex'
|
||||
import rehypeSlug from 'rehype-slug'
|
||||
import rehypeExternalLinks from 'rehype-external-links'
|
||||
import { getPosts, getPost } from '@/lib/posts'
|
||||
import { TableOfContents } from '@/components/blog/TableOfContents'
|
||||
import { ScrollToTop } from '@/components/ui/ScrollToTop'
|
||||
@@ -54,9 +57,10 @@ export default async function PostPage({ params }: { params: Promise<{ slug: str
|
||||
components={useMDXComponents({})}
|
||||
options={{
|
||||
mdxOptions: {
|
||||
remarkPlugins: [remarkMath, remarkGfm],
|
||||
rehypePlugins: [
|
||||
remarkPlugins: [smartypants, remarkMath, remarkGfm],
|
||||
rehypePlugins: [
|
||||
rehypeSlug,
|
||||
rehypeAutolinkHeadings,
|
||||
[rehypePrettyCode, { theme: 'github-dark' }],
|
||||
rehypeKatex,
|
||||
],
|
||||
|
||||
Reference in New Issue
Block a user