This repo contains Hakyll-based personal blog of Dmitry Dzhus. It replaces the old Django-based blog engine which was used in 2006-2012.
-
Home page
-
Extract title from the first
<h1>
heading in the file -
Mobile view with responsive design
-
Multi-language support
Language-specific sections: post page, feeds, post list, tags, pagination.
Each entry can hava a language specified via
lang
metadata field. There are feeds in both languages. Template must depend on entry language. Next/previous page links must lead to entries in the same language. -
Atom feeds
-
Sitemap for posts
-
Source code highlighting and scrolling
-
Next/previous page link
-
modificationTimeField
for each entry is populated from the author date of its latest Git revision
- Presumably due to pagination/tags code, all pages are rebuilt after even a single post is modified.
The last big changes to the old engine were made somewhere in 2009. In 2017, the state of the Semantic Web tech adoption has changed (positively) compared to 2010s:
-
HTML5 is mainstream
-
Microformats, RDFa were «superseded» by microformats2
-
Some
<link>
rel
values were dropped
It's possible to get Pandoc to include table of contents in the HTML generated for a Markdown post with something like
pandocCompilerWith defaultHakyllReaderOptions defaultHakyllWriterOptions{writerTemplate=Just "$toc$ $body$", writerTOCDepth = 4, writerTableOfContents = True}
Ideally we'd want to place TOC in the post manually (for example by
placing <!-- toc -->
comment at the desired position).
Perhaps it's best to leave it to the client.