Skip to content

Commit 5c4ed04

Browse files
committed
Added removeEmpty tags for EditorContent
1 parent 63dfeea commit 5c4ed04

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

Diff for: src/components/EditorContent/index.jsx

+2-1
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@ import { createRoot } from "react-dom/client";
88

99
import { EDITOR_SIZES } from "src/common/constants";
1010
import "src/styles/editor/editor-content.scss";
11+
import { removeEmptyTags } from "utils";
1112

1213
import {
1314
EDITOR_CONTENT_CLASS_NAME,
@@ -34,7 +35,7 @@ const EditorContent = ({
3435
const editorContentRef = useRef(null);
3536

3637
const htmlContent = substituteVariables(
37-
applySyntaxHighlightingAndLineNumbers(content),
38+
applySyntaxHighlightingAndLineNumbers(removeEmptyTags(content)),
3839
variables
3940
);
4041
const sanitize = DOMPurify.sanitize;

0 commit comments

Comments
 (0)