File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 11import { Collapse , Divider , Image , Typography } from 'antd' ;
22import { CSSProperties , memo } from 'react' ;
3- import { ErrorBoundary } from 'react-error-boundary' ;
43import ReactMarkdown from 'react-markdown' ;
54import rehypeKatex from 'rehype-katex' ;
65import remarkGfm from 'remark-gfm' ;
@@ -45,28 +44,15 @@ const Markdown = memo<MarkdownProps>(
4544
4645 return (
4746 < Typography className = { className } onDoubleClick = { onDoubleClick } style = { style } >
48- < ErrorBoundary
49- fallback = {
50- < ReactMarkdown
51- className = { styles . markdown }
52- components = { components }
53- remarkPlugins = { [ remarkGfm ] }
54- { ...rest }
55- >
56- { children }
57- </ ReactMarkdown >
58- }
47+ < ReactMarkdown
48+ className = { styles . markdown }
49+ components = { components }
50+ rehypePlugins = { [ rehypeKatex ] }
51+ remarkPlugins = { [ remarkGfm , remarkMath ] }
52+ { ...rest }
5953 >
60- < ReactMarkdown
61- className = { styles . markdown }
62- components = { components }
63- rehypePlugins = { [ rehypeKatex ] }
64- remarkPlugins = { [ remarkGfm , remarkMath ] }
65- { ...rest }
66- >
67- { children }
68- </ ReactMarkdown >
69- </ ErrorBoundary >
54+ { children }
55+ </ ReactMarkdown >
7056 </ Typography >
7157 ) ;
7258 } ,
You can’t perform that action at this time.
0 commit comments