02 November 2014

Markdown

Markdown is the language which drives most of the content on this page. Instead of writing HTML code you have a higher level language to define how the content looks like. A markdown parser takes the markdown code and translates it to HTML code.

Parsers available on GitHub

To get a list of available markdown parsers please refer to Github Pages Dependency versions.

Configuration

You can configure which markdown parser should be used. Refer to the _config.yml file in the root directory and look for the “markdown” key. The parser used for this blog is kramdown .

markdown: kramdown

On GitHub there are 3 different options available:

  • maruku (depricated, do not use)
  • kramdown
  • redcarpet
  • rdiscount

Kramdown

The documentation can be found on the Kramdown homepage.

Useful features

  • define a target attribut for links:
[Link Title](http://xyz.github.io/){:target="_self"}

Quirks

There needs to be a blank line before the heading definition. RDiscount is more tolerant and renders the headings even without a blank line. Therefore I needed to adjust the “partials” for the jsdoc-to-markdown process while generating the ApiDoc.

Redcarpet

The documentation can be found on the Redcarpet GitHub repository. Redcarpet is released by GitHub

RDiscount

The documentation can be found on RDiscount GitHub repository.

Quirks

It doesn’t support adding a target attribute to a link (see section “Cool Features” for kramdown). This is necessary because html5 mode is enabled on this page. In html5 mode every link needs to contain a target='_self' attribute to redirect to the link you clicked on.

Drop me a line!