From 4238b9b3efc3a9c001b5e1cf6c1883ffd0f92800 Mon Sep 17 00:00:00 2001 From: Literallie Date: Wed, 18 Oct 2017 19:37:55 +0200 Subject: Fix MathJax CSP issues --- public/js/mathjax-config-extra.js | 8 ++++++++ public/views/hackmd/foot.ejs | 4 +--- public/views/pretty.ejs | 4 +--- public/views/slide.ejs | 4 +--- 4 files changed, 11 insertions(+), 9 deletions(-) create mode 100644 public/js/mathjax-config-extra.js (limited to 'public') diff --git a/public/js/mathjax-config-extra.js b/public/js/mathjax-config-extra.js new file mode 100644 index 00000000..54cee794 --- /dev/null +++ b/public/js/mathjax-config-extra.js @@ -0,0 +1,8 @@ +var MathJax = { + messageStyle: 'none', + skipStartupTypeset: true, + tex2jax: { + inlineMath: [['$', '$'], ['\\(', '\\)']], + processEscapes: true + } +} diff --git a/public/views/hackmd/foot.ejs b/public/views/hackmd/foot.ejs index 6a1f3b99..8438dce2 100644 --- a/public/views/hackmd/foot.ejs +++ b/public/views/hackmd/foot.ejs @@ -1,6 +1,4 @@ - + <% if(useCDN) { %> diff --git a/public/views/pretty.ejs b/public/views/pretty.ejs index 80d2505c..b2988e39 100644 --- a/public/views/pretty.ejs +++ b/public/views/pretty.ejs @@ -72,9 +72,7 @@ - + <% if(useCDN) { %> diff --git a/public/views/slide.ejs b/public/views/slide.ejs index c7dd9898..269ce044 100644 --- a/public/views/slide.ejs +++ b/public/views/slide.ejs @@ -89,9 +89,7 @@ - + <% if(useCDN) { %> -- cgit v1.2.3