Ghost & MathJax

While Ghost seems to be a great choice as blogging platform, it'd still be cool if I could have support for LaTeX via MathJax, as there will be quite a few formula in this blog.

Fortunately, it's quite easy to integrate MathJax into virtually any web platform, in the case of Ghost the (okay, somewhat hackish) steps are:

  • open ghost/content/themes/casper/default.hbs in your favourite editor
  • add <script type="text/javascript" src="//cdn.mathjax.org/mathjax/latest/MathJax.js?config=TeX-AMS-MML_HTMLorMML"> </script> right before the </head>. Using // will automatically determine whether http or https shall be used
  • save the file, and restart Ghost

Now you're ready to enjoy all the \(LaTeX\) goodness MathJax brings to your website!

Updated 2015-02-08: MathJax' CDN now supports HTTPS in general, adapted the script URL for that.