Skip to content

Commit 8f3a677

Browse files
committed
support gfm
1 parent 01f75ad commit 8f3a677

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

src/components/SupportAI.tsx

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
import { useState } from "react";
22
import Markdown from "react-markdown";
3+
import remarkGfm from "remark-gfm";
34
import { fetchEventSource } from "@microsoft/fetch-event-source";
45
import { Ring } from "ldrs/react";
56
import "ldrs/react/Ring.css";
@@ -29,7 +30,7 @@ function Messages({
2930
key={index}
3031
className={`${classes.base} ${message.role === "user" ? classes.user : classes.assistant}`}
3132
>
32-
<Markdown>{message.content}</Markdown>
33+
<Markdown remarkPlugins={[remarkGfm]}>{message.content}</Markdown>
3334
</div>
3435
))}
3536
{loading && (

0 commit comments

Comments
 (0)