diff --git a/components/JsonToHtml/renderOptions.tsx b/components/JsonToHtml/renderOptions.tsx index 7f8420bf6..5b4eda0d7 100644 --- a/components/JsonToHtml/renderOptions.tsx +++ b/components/JsonToHtml/renderOptions.tsx @@ -526,6 +526,8 @@ export const renderOptions: RenderOptions = { ) => { const props = extractPossibleAttributes(node.attrs) + props.className = props.className || "" + if (props.className) { if (hasAvailableULFormat(props.className)) { // @ts-ignore: We want to set css modules classNames even if it does not correspond @@ -547,7 +549,7 @@ export const renderOptions: RenderOptions = {