aboutsummaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
authorHakim El Hattab <hakim.elhattab@gmail.com>2012-07-31 12:44:37 -0300
committerHakim El Hattab <hakim.elhattab@gmail.com>2012-07-31 12:44:37 -0300
commitff567372c09c5c6b2f527050bb9814179201bb5e (patch)
tree60a6665e8d6ce618de74557316af8e63a93c7e44 /lib
parent12c9977cda3ceed969c3b24a15dfe33eb2a3e7e4 (diff)
downloadfosdem-2018-presentation-ff567372c09c5c6b2f527050bb9814179201bb5e.tar
fosdem-2018-presentation-ff567372c09c5c6b2f527050bb9814179201bb5e.tar.gz
self-execute data-markdown
Diffstat (limited to 'lib')
-rw-r--r--lib/js/data-markdown.js6
1 files changed, 3 insertions, 3 deletions
diff --git a/lib/js/data-markdown.js b/lib/js/data-markdown.js
index d1b27c4..3c5389b 100644
--- a/lib/js/data-markdown.js
+++ b/lib/js/data-markdown.js
@@ -1,8 +1,8 @@
// From https://gist.github.com/1343518, modified to not load showdown
-(function boom(){
+(function(){
[].forEach.call( document.querySelectorAll('[data-markdown]'), function fn(elem){
-
+
// strip leading whitespace so it isn't evaluated as code
var text = elem.innerHTML.replace(/\n\s*\n/g,'\n'),
// set indentation level so your markdown can be indented within your HTML
@@ -16,4 +16,4 @@
});
-}()); \ No newline at end of file
+})(); \ No newline at end of file