We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 459c373 commit 9a86c42Copy full SHA for 9a86c42
app/components/markdown.tsx
@@ -90,7 +90,11 @@ export function PreCode(props: { children: any }) {
90
const refText = ref.current.querySelector("code")?.innerText;
91
if (htmlDom) {
92
setHtmlCode((htmlDom as HTMLElement).innerText);
93
- } else if (refText?.startsWith("<!DOCTYPE")) {
+ } else if (
94
+ refText?.startsWith("<!DOCTYPE") ||
95
+ refText?.startsWith("<svg") ||
96
+ refText?.startsWith("<?xml")
97
+ ) {
98
setHtmlCode(refText);
99
}
100
}, 600);
0 commit comments