From 0d02d8a303a39b02c919d86c94ec477d1e1b107d Mon Sep 17 00:00:00 2001 From: Hakim El Hattab Date: Mon, 18 Nov 2024 08:26:23 +0100 Subject: [PATCH] default mathjax config now ignores code tags --- plugin/math/mathjax2.js | 2 +- plugin/math/mathjax3.js | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/plugin/math/mathjax2.js b/plugin/math/mathjax2.js index daebe7e86b3..17df85c960b 100644 --- a/plugin/math/mathjax2.js +++ b/plugin/math/mathjax2.js @@ -13,7 +13,7 @@ export const MathJax2 = () => { messageStyle: 'none', tex2jax: { inlineMath: [ [ '$', '$' ], [ '\\(', '\\)' ] ], - skipTags: [ 'script', 'noscript', 'style', 'textarea', 'pre' ] + skipTags: [ 'script', 'noscript', 'style', 'textarea', 'pre', 'code' ] }, skipStartupTypeset: true }; diff --git a/plugin/math/mathjax3.js b/plugin/math/mathjax3.js index 767129c1c13..68572aa1ff2 100644 --- a/plugin/math/mathjax3.js +++ b/plugin/math/mathjax3.js @@ -15,7 +15,7 @@ export const MathJax3 = () => { inlineMath: [ [ '$', '$' ], [ '\\(', '\\)' ] ] }, options: { - skipHtmlTags: [ 'script', 'noscript', 'style', 'textarea', 'pre' ] + skipHtmlTags: [ 'script', 'noscript', 'style', 'textarea', 'pre', 'code' ] }, startup: { ready: () => {