diff options
author | Dan Ovando <DanOvando@users.noreply.github.com> | 2018-02-25 07:19:58 +0300 |
---|---|---|
committer | Patrick Collins <thepatrickcollins@gmail.com> | 2018-02-25 07:19:58 +0300 |
commit | 62b074f4db1e5170f25d77d0c03181c94e6c1018 (patch) | |
tree | 1d9dce903192df86f39320f3e917c1b32f10c73c | |
parent | 187e213d406e03aa8cc2fa755231433c5f5aa083 (diff) |
Add capability for mathjax equations per instructions here (#126)
https://bookdown.org/yihui/blogdown/templates.html
-rw-r--r-- | exampleSite/config.toml | 6 | ||||
-rw-r--r-- | layouts/partials/footer.html | 1 | ||||
-rw-r--r-- | layouts/partials/footer_mathjax.html | 5 |
3 files changed, 10 insertions, 2 deletions
diff --git a/exampleSite/config.toml b/exampleSite/config.toml index 001ccd4..e171304 100644 --- a/exampleSite/config.toml +++ b/exampleSite/config.toml @@ -63,7 +63,9 @@ pluralizeListTitles = false highlightjsCDN = "//cdn.bootcss.com" highlightjsLang = ["r", "yaml", "css"] highlightjsTheme = "github" - + MathJaxCDN = "//cdn.bootcss.com" + MathJaxVersion = "2.7.1" + # Disqus will take priority over Staticman (github.com/eduardoboucas/staticman) # due to its ease of use. Feel free to check out both and decide what you would # prefer to use. See Staticman.yml for additional settings. @@ -187,6 +189,6 @@ pluralizeListTitles = false vine = "" googlescholar = "" orcid = "" - researchgate = "example" + researchgate = "example" # Email email = "example" diff --git a/layouts/partials/footer.html b/layouts/partials/footer.html index 0353f4b..dcc917f 100644 --- a/layouts/partials/footer.html +++ b/layouts/partials/footer.html @@ -41,5 +41,6 @@ <!-- This is called by default since this theme uses highlight.js --> <script>hljs.initHighlightingOnLoad();</script> + {{ partial "footer_mathjax" . }} </body> </html> diff --git a/layouts/partials/footer_mathjax.html b/layouts/partials/footer_mathjax.html new file mode 100644 index 0000000..bd331bc --- /dev/null +++ b/layouts/partials/footer_mathjax.html @@ -0,0 +1,5 @@ +<script src="//yihui.name/js/math-code.js"></script> +<script async +src="{{ .Site.Params.MathJaxCDN | default "//cdn.bootcss.com"}}/mathjax/{{ .Site.Params.MathJaxVersion | default "2.7.1" }}/MathJax.js?config=TeX-MML-AM_CHTML"> +</script> + |