diff options
author | liz2020 <lihaozhu2020@gmail.com> | 2020-11-20 23:38:34 +0300 |
---|---|---|
committer | liz2020 <lihaozhu2020@gmail.com> | 2020-11-20 23:38:34 +0300 |
commit | 8f4225ea8fd26b61b310f4f760482690c0755942 (patch) | |
tree | 4788b9d025aafe992559e3ba019a9efcc0177370 /README.md | |
parent | 28dcf728cb5883818bc4f1d17c78a74afd947def (diff) |
add latex support; activate when latex: true is set in markdown file
Diffstat (limited to 'README.md')
-rw-r--r-- | README.md | 17 |
1 files changed, 16 insertions, 1 deletions
@@ -56,7 +56,7 @@ summary: "The summary content" --- ``` -### Approch 2: use <!--more--> +### Approch 2: use `<!--more-->` Use `<!--more-->` to seperate content that will display in the posts page as abstraction and the rest of the content. This is different from summary, as summary will not appear in the post. ``` --- @@ -69,6 +69,21 @@ abstraction show in the post page other content ``` +## Support LaTex +In you post add `katex:true` to [front matter](https://gohugo.io/content-management/front-matter/) +``` +--- +katex: true +--- +``` +Then the [katex script](https://katex.org/docs/autorender.html) will auto render the string enclosed be delimiters. +``` +# replace ... with latex formula +display inline \\( ... \\) +display block $$ ... $$ +``` +![latex example](images/latex_example.png) + ## config.toml example ```toml |