Using markdowns for templates in Hakyll

Using the skeleton website created with hakyll-init site_foo, I want to translate site_foo/index.htmlinto markdowns and save its contents.

In other words, refers to posts-list.

I do not know what functions would be combined to achieve the right Compilertomatch "index.markdown"

+4
source share
1 answer

Assuming you have already created your index.markdownfile for replacement index.html, you can modify site.hsit to look like this:

getResourceBody
    >>= applyAsTemplate indexCtx
    >>= return . renderPandoc
    >>= loadAndApplyTemplate "templates/default.html" indexCtx
    >>= relativizeUrls

The new line - the third, >>= return . renderPandoc.

Pandoc HTML, HTML, Pandoc .

, Hakyll: https://groups.google.com/forum/#!topic/hakyll/ooMEwuiQZ24

+3

All Articles