Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
  • Loading branch information
algasami committed May 13, 2024
1 parent c39119b commit 22f7ee1
Show file tree
Hide file tree
Showing 6 changed files with 346 additions and 24 deletions.
2 changes: 1 addition & 1 deletion app/[lang]/posts/[slug]/page.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,8 @@ import {
} from "app/components/mdxHeadings";
import { useEffect } from "react";
import { buildProps } from "./utils";
import { useParams, usePathname } from "next/navigation";
import { useHash } from "app/components/hash-utils";
import "katex/dist/katex.min.css";

type TProps = { params: { slug: string; lang: Locale } };

Expand Down
2 changes: 0 additions & 2 deletions app/components/postBody/PostBody.module.scss
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
@import url("https://cdn.jsdelivr.net/npm/[email protected]/dist/katex.min.css");

.postBody {
@apply text-xl leading-loose;
font-variant-ligatures: none;
Expand Down
2 changes: 1 addition & 1 deletion contentlayer.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -52,10 +52,10 @@ export default makeSource({
mdx: {
remarkPlugins: [remarkMath],
rehypePlugins: [
rehypeKatex,
rehypeSlug,
rehypeCodeTitles,
[rehypePrism, { ignoreMissing: true }],
rehypeKatex,
] as any,
},
});
2 changes: 2 additions & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,7 @@
"clsx": "^2.1.0",
"contentlayer": "^0.3.4",
"date-fns": "^3.3.1",
"katex": "^0.16.10",
"material-symbols": "^0.15.0",
"next": "14.1.0",
"next-contentlayer": "^0.3.4",
Expand All @@ -32,6 +33,7 @@
"react-dom": "18.2.0",
"rehype-code-titles": "^1.2.0",
"rehype-katex": "^7.0.0",
"rehype-mathjax": "^6.0.0",
"rehype-prism-plus": "^2.0.0",
"rehype-slug": "^6.0.0",
"remark-math": "^6.0.0",
Expand Down
Loading

0 comments on commit 22f7ee1

Please sign in to comment.