chatbot-template/app/markdown.tsx
Jared Palmer a04776256d init
2023-05-19 12:33:56 -04:00

9 lines
293 B
TypeScript

import { FC, memo } from "react";
import ReactMarkdown, { Options } from "react-markdown";
export const MemoizedReactMarkdown: FC<Options> = memo(
ReactMarkdown,
(prevProps, nextProps) =>
prevProps.children === nextProps.children &&
prevProps.className === nextProps.className
);