恢复博客
下载Git仓库中的历史版本文件,解压到目标本地文件夹或直接git-clone
Git bash重新安装hexo
rm -rf node_modules |
额外备份了主题文件夹,直接将备份的next主题文件夹覆盖theme中的文件夹
接下来hexo clean, g, s, d普通操作就可以了
启用mathjax
next文件夹中的_config.yml文件mathjax设为true
安装hexo-renderer-pandoc
$ npm un hexo-renderer-marked |
打开 Hexo 项目目录下的 themes/next/layout/_layout.swig
文件。
在该文件的 <head>
标签中添加以下代码
<script type="text/javascript" async |
\[\begin{equation} e=mc^2 \end{equation}\]
The famous matter-energy equation proposed by Einstein...
This is an inline math expression: \(E=mc^2\). This is a displayed math expression: \[ \sum_{i=1}^{n} i = \frac{n(n+1)}{2} \]