import { memo } from "react"; import type { Components } from "react-markdown"; import ReactMarkdown from "react-markdown"; import rehypeHighlight from "rehype-highlight"; import remarkGfm from "remark-gfm"; interface ChatMarkdownProps { text: string; } const markdownComponents: Components = { a({ node: _node, ...props }) { return ; }, }; function ChatMarkdown({ text }: ChatMarkdownProps) { return (
{text}
); } export default memo(ChatMarkdown);