File size: 290 Bytes
15bfa8d
 
 
 
 
 
 
 
 
1
2
3
4
5
6
7
8
9
10
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
)