Why Hakyll?

Posted on February 12, 2021

Hakyll is the choice of static site generator for this website. It is chosen because:

  1. Pandoc supports a plethora of formats
  2. Hakyll allows immensely powerful customization
  3. I like Haskell

The blogs will most likely be written in Markdown. More specifically, Pandoc’s flavor of Markdown, which supports cool things like:

\[ \oiint_{\partial\Omega} \mathbf{E} \cdot d\mathbf{S} = {1\over\epsilon_0}\iiint_\Omega \rho dV \] 1 which is the Gauss’s law written as an integral equation.

Note that there is a small hack here: the backend compiles equation as MathJax, but I use KaTeX scripts to render them on the page. This is because KaTeX supports more symbols than MathJax, such as the double surface integral symbol above.

The only difference between the two is that Pandoc compiles MathJax equations surrounded with \[ and \]. This allows KaTeX’s auto rendering script to recognize equations on the web page and replace them with equations.

Update 2021-02-23

Try out the aligned environment: \[ \begin{aligned} \oiint_{\partial\Omega} \mathbf{E} \cdot \mathrm{d}\mathbf{S} &= {1\over\epsilon_0}\iiint_\Omega \rho \mathrm{d}V \\ \oiint_{\partial\Omega} \mathbf{B} \cdot \mathrm{d}\mathbf{S} &= 0 \\ \oint_{\partial\Sigma} \mathbf{E} \cdot \mathrm{d}\mathbf{l} &= -{\mathrm{d}\over\mathrm{d}t} \iint_\Sigma \mathbf{B} \cdot \mathrm{d}\mathbf{S} \\ \oint_{\partial\Sigma}\mathbf{B} \cdot \mathrm{d}\mathbf{l} &= \mu_0\left(\iint_\Sigma \mathbf{J}\cdot \mathrm{d}\mathbf{S} + \epsilon_0{\mathrm{d}\over\mathrm{d}t}\iint_\Sigma \mathbf{E}\cdot\mathrm{d}\mathbf{S} \right) \end{aligned} \]


  1. https://en.wikipedia.org/wiki/Maxwell%27s_equations↩︎