0
0
mirror of https://github.com/naturalcrit/homebrewery.git synced 2025-12-25 18:22:42 +00:00

Add renderer option to HTML blocks in Markdown

This commit is contained in:
G.Ambatte
2023-02-20 21:35:00 +13:00
parent fe5e91c377
commit 17525a4f41

View File

@@ -10,7 +10,7 @@ renderer.html = function (html) {
const openTag = html.substring(0, html.indexOf('>')+1);
html = html.substring(html.indexOf('>')+1);
html = html.substring(0, html.lastIndexOf('</div>'));
return `${openTag} ${Marked.parse(html)} </div>`;
return `${openTag} ${Marked.parse(html, { renderer: renderer })} </div>`;
}
return html;
};