I mentioned yesterday that I couldn't remember what I didn't like about Hugo's parsing of Org mode in the past. When I viewed the published post, I quickly remembered what it was: footnotes. If I remember correctly, at the time that I first tried using native Org mode parsing, Hugo didn't parse the footnotes at all. Now, it does, but they render in an odd way. The footnote number is in subscript on one line, followed by a blank line, followed by the footnote text on another line. So, instead of getting something like this:
|
|
We get this:
|
|
A Google search resulted in one question on the Hugo help forum, but no good answer. The problem is the way that Hugo renders the HTML. In a Markdown post, this content
|
|
results in this HTML code:
|
|
This turns the footnotes into numbered list items that end with a nice return character that is linked to the footnote number in the text.
This Org mode content, however,
|
|
renders like this:
|
|
Notice that there is no list, instead the footnote text is separated from the number by a <div>
, which is normally rendered as an empty line.
Hacking around with some CSS, I managed to get the number and the text on the same line.1 Here's the CSS code:
|
|
I'm not quite satisfied with the superscript number in the footnote, but I haven't found a good fix for that yet.
Like this.