aboutsummaryrefslogtreecommitdiff
path: root/plugin/markdown
diff options
context:
space:
mode:
authorasmod3us <4sm0d3us@gmail.com>2013-02-26 16:06:18 +0100
committerasmod3us <4sm0d3us@gmail.com>2013-02-26 16:06:18 +0100
commitf095af212ee2b6009412a89fe17ae46860efd8df (patch)
treed5908e1c281db0b022903d85d5d6efb7420c4450 /plugin/markdown
parent7207122c75137c0d2c7dfd0e1d9a1a0e9bf0a88f (diff)
downloadfosdem-2018-presentation-f095af212ee2b6009412a89fe17ae46860efd8df.tar
fosdem-2018-presentation-f095af212ee2b6009412a89fe17ae46860efd8df.tar.gz
Update plugin/markdown/markdown.js
Use textContent instead of innerHTML to prevent encoding of certain characters in Markdown code blocks.
Diffstat (limited to 'plugin/markdown')
-rw-r--r--plugin/markdown/markdown.js2
1 files changed, 1 insertions, 1 deletions
diff --git a/plugin/markdown/markdown.js b/plugin/markdown/markdown.js
index ae4d08b..39e1168 100644
--- a/plugin/markdown/markdown.js
+++ b/plugin/markdown/markdown.js
@@ -11,7 +11,7 @@
var template = section.querySelector( 'script' );
// strip leading whitespace so it isn't evaluated as code
- var text = ( template || section ).innerHTML;
+ var text = ( template || section ).textContent;
var leadingWs = text.match(/^\n?(\s*)/)[1].length,
leadingTabs = text.match(/^\n?(\t*)/)[1].length;