From f6f3d298cc12b54878a1019ee41335a75ca28aa3 Mon Sep 17 00:00:00 2001 From: Alexandros Date: Thu, 28 May 2020 00:25:02 +0300 Subject: [PATCH] Upgrade KaTex + workaround for Inline Math For an equation to render inline make sure to wrap it within an inline shortcode so that the Markdown processor is not used for parsing. Also note that for inline KaTex since `katex@0.11.1` use the `\( ... \)` delimiters and not the `$` sign. Closes: #60 --- content/post/math-typesetting.md | 14 ++++++++------ 1 file changed, 8 insertions(+), 6 deletions(-) diff --git a/content/post/math-typesetting.md b/content/post/math-typesetting.md index a1467e32..ab7b3af5 100644 --- a/content/post/math-typesetting.md +++ b/content/post/math-typesetting.md @@ -27,18 +27,20 @@ In this example we will be using [KaTeX](https://katex.org/) {{< math.inline >}} {{ if or .Page.Params.math .Site.Params.math }} - - - + + + {{ end }} {{}} ### Examples - -Inline math: $$ \varphi = \dfrac{1+\sqrt5}{2}= 1.6180339887… $$ +{{< math.inline >}} +

+Inline math: \(\varphi = \dfrac{1+\sqrt5}{2}= 1.6180339887…\) +

+{{}} Block math: - $$ \varphi = 1+\frac{1} {1+\frac{1} {1+\frac{1} {1+\cdots} } } $$