When exporting and org file in emacs to either html or md for a jekyll-based web page, the yaml
front matter gets twisted.
As suggested here, I have attempted enclosing it in an html block in the org file thus:
#+begin_html
---
layout: post
title: "La redistritación"
---
#+end_html
It should output this:
---
layout: post
title: "La redistritación"
---
Using org-html-publish-to-html
, I instead get this:
<div class="html">
<p>
—
layout: post
title: "La redistritación"
—
</p>
</div>
I also attempted enclosing in a source block (as suggested here) thus:
#+begin_src yaml
---
layout: post
title: "La redistritación"
---
#+end_src
which comes close, but prepends empty (code) spaces and is therefore not recognized as front matter by jekyll.
(And adding exports
and results
specs, as suggested here, returns a Wrong type argument: stringp, nil
error message.)
How should I configure export settings to get proper yaml front matter?
org-mode
seems to have taken care of the error message. It now exports front-matter thatjekyll
recognizes as such. But am still puzzled as to why the first approach will not work...