11 lines
368 B
TypeScript
11 lines
368 B
TypeScript
import ReactMarkdown from "react-markdown";
|
|||
|
|
import remarkGfm from "remark-gfm";
|
||
|
|
|
||
|
|
export function MarkdownViewer({ content }: { content: string }) {
|
||
|
|
return (
|
||
|
|
<div className="prose prose-neutral dark:prose-invert max-w-none prose-pre:bg-muted prose-pre:text-foreground">
|
||
|
|
<ReactMarkdown remarkPlugins={[remarkGfm]}>{content}</ReactMarkdown>
|
||
|
|
</div>
|
||
|
|
);
|
||
|
|
}
|