我选择的这个主题没有自带数学渲染器,(但写文章怎么能没有latex呢),所以就寻找安装latex办法这里给出一种简单方法。qwq
安装
1 | $ npm install hexo-filter-mathjax |
配置
在博客目录下的_config.yml内添加
1 | mathjax: |
在需要加载latex的front-matter写入mathjax: true
注意
- 单个美元符号引入的公式美元符号,开头的$后和结尾的$前不能有空格
- 如果latex内符号和markdown语法有冲突 请用\转义 如* 要写成\*
- this 可以将你的latex转义