Reputation: 2548
EDIT: I answered my question--sort of--but the answer makes me angrier than the problem did. If the markdown file ends with a \n
the converter works exactly as expected. If the markdown file ends with a letter or a period (or any other character, presumably), I get the issue. So far, my fix has been content += "\n"
but I have no idea why that works. So the question still stands, I guess.
I have written a Jekyll converter that takes a series of footnotes out of a markdown document and appends them to the end of that same document as an <ul>
with a series of <li>
tags.
The converter works great, except that the <ul>
and <li>
tags are being escaped somewhere along the line and appear as regular text along with the rest of the document.
That is, I should get:
But instead I get:
<ul><li>Footnote1</li><li>Footnote2</li></ul>
So, I assume the markdown conversion happens after custom converters run and markdown is escaping the tags, but I don't actually know. Is a converter the appropriate place to do create the footnotes? If so, how can I ask markdown to leave my tags alone?
If it is relevant, the content is inserted via {{ content }}
Upvotes: 2
Views: 232
Reputation: 52809
Try :
{::nomarkdown}
your code here
{:/nomarkdown}
or
Remove all indentation from your generated code. If you have four space indentation, kramdown treat this like code.
Upvotes: 4