no empty markup divs

This commit is contained in:
Jeremy Kauffman 2018-10-11 20:26:02 -04:00
parent 52c37cf62f
commit 4795d87de5

View file

@ -50,7 +50,7 @@ export default path => {
const updatedMarkdown = wikiFinder(partialFinder(renderedMarkdown)); const updatedMarkdown = wikiFinder(partialFinder(renderedMarkdown));
return html` return html`
<div class="page__markup">${raw(updatedMarkdown)}</div> ${raw(updatedMarkdown)}
`; `;
}; };
@ -81,7 +81,7 @@ function partialFinder(markdownBody) {
} }
} }
return markdownBody; return ("<div class=\"page__markup\">" + markdownBody + "</div>").replace(/<div class="page__markup">\s*<\/div>/, "");
} }
function wikiFinder(markdownBody) { function wikiFinder(markdownBody) {