mirror of
https://github.com/naturalcrit/homebrewery.git
synced 2026-01-10 09:12:39 +00:00
Add renderer option to HTML blocks in Markdown
This commit is contained in:
@@ -10,7 +10,7 @@ renderer.html = function (html) {
|
|||||||
const openTag = html.substring(0, html.indexOf('>')+1);
|
const openTag = html.substring(0, html.indexOf('>')+1);
|
||||||
html = html.substring(html.indexOf('>')+1);
|
html = html.substring(html.indexOf('>')+1);
|
||||||
html = html.substring(0, html.lastIndexOf('</div>'));
|
html = html.substring(0, html.lastIndexOf('</div>'));
|
||||||
return `${openTag} ${Marked.parse(html)} </div>`;
|
return `${openTag} ${Marked.parse(html, { renderer: renderer })} </div>`;
|
||||||
}
|
}
|
||||||
return html;
|
return html;
|
||||||
};
|
};
|
||||||
|
|||||||
Reference in New Issue
Block a user