Background
I’m recently enhancing the $\rm \LaTeX$ code for inline limits. For the reason of doing so, you may refer to the external link of my recent linklog Inline Limit Rendering.
Problem
In the previous post in this series written over one year ago, I have included a code block which enables deferred MathJax loading. However, I manually added this chuck of code in the HTML file generated by kramdown, which created the problem described in the next subsection A problem with Vim’s folding arised.
Solution
Firstly, save the code for loading MathJax in the previous
post in this series in a separate file ~/script.html
. Then
use the following commands within Vim in order to avoid leaving the
current buffer and to improve efficiency.
9,$w! ~/temp.mkd
!kramdown ~/temp.mkd > ~/temp.html
!cat ~/{temp,script}.html > ~/test.html
The digit 9
in the first command isn’t exact. Change it to any
line number that separates the yaml front matter from the
post content.