

Under Preferences, choose the Style tab and check Enable MathJax. On the other hand, if you use the magnificent Marked 2 program to render your HTML, well, it has MathJax support built-in. That forces the preview pane to reload both the rendering template and the page. If you see something like the image on the right, just right-click on the preview-pane and click Reload. Note: Occasionally the preview will fail to render the MathJax, either because the MathJax is invalid or the refresh fails to reload the Javascript. Next time iA Writer, Byword or Ulysses loads its preview pane and renders the page, the javascript will run and render the MathJax as mathematical formulae. In the main html file, called document.html in the iA template, add the MathJax javascript header line:
#Markdown math how to
To add MathJax rendering in iA Writer, Byword, Ulysses and most others, you need to create a custom template to render the document (I assume you have done this already - see Letterhead - Markdown Style for an example).įor iA Writer, for example, go to Preferences, select the Templates tab and click the plus below Custom Templates, and choose Open Documentation to learn how to create your own template.

Most Markdown Editors have a Preview function, but do not include MathJax by default. For centered formulae, use \\.įor example, the formula: \\[ x = + c = 0 \).MathJax in MarkdownĪdding mathematical formulae to a markdown document simply requires you to use the MathJax delimiters to start and end each formula as follows: This post shows how to add mathematical formulae to your Markdown documents on the Mac and have them preview and export to PDF correctly. But I create all my documents in Markdown format on my Mac. Adding mathematical formulae to HTML pages is easy these days using MathJax.
