Skip to content

Commit a9f37ca

Browse files
committed
fix: math render escape html with br
1 parent a1a1f32 commit a9f37ca

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/utils/mathRenderer.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ export function containsMath(text: string): boolean {
2121
export function escapeHtml(doc: Document, text: string): string {
2222
const div = doc.createElement("div");
2323
div.textContent = text;
24-
return div.innerHTML.replace(/\n/g, "<br>");
24+
return div.innerHTML.replace(/\n/g, "<br></br>");
2525
}
2626

2727
export function renderMathInText(doc: Document, text: string): string {

0 commit comments

Comments
 (0)