-
Notifications
You must be signed in to change notification settings - Fork 12
/
markdown.config.ts
44 lines (37 loc) · 1.18 KB
/
markdown.config.ts
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
35
36
37
38
39
40
41
42
43
44
//? [MarkDown] -> [Configuration]
//* [Plugins] -> [Table of Contents]
//import remarkToc from "remark-toc";
//import rehypeToc from "rehype-toc";
//! [March 14, 2023] - Adding rehype-external-links
import rehypeExternalLinks from "rehype-external-links";
//! Removal of the core plugins.
//! import rehypeSlug from "rehype-slug"; There is a bug with displaying the Table of Contents , when importing the .MD files inside of the .MDX
import { rehypeHeadingIds } from "@astrojs/markdown-remark";
//! [June 13, 2023] - Adding Mermaid
import { mermaid } from "./src/components/Library/MDX/mermaid"
export default {
extendMarkdownConfig: true,
rehypePlugins: [
rehypeHeadingIds,
[
rehypeExternalLinks,
{
rel: ["nofollow", "noopener", "noreferrer"],
target: ["_blank"],
},
],
//! rehypeSlug errors
],
//? Shiki Configuration
shikiConfig: {
// https://github.com/shikijs/shiki/blob/main/docs/themes.md
theme: "dracula",
// https://github.com/shikijs/shiki/blob/main/docs/languages.md
langs: [],
wrap: true,
},
//? External Plugins -> True
extendPlugins: true,
gfm: true,
remarkPlugins: [mermaid],
};