summaryrefslogtreecommitdiffstats
path: root/lib/utils/page.js
diff options
context:
space:
mode:
Diffstat (limited to 'lib/utils/page.js')
-rw-r--r--lib/utils/page.js7
1 files changed, 4 insertions, 3 deletions
diff --git a/lib/utils/page.js b/lib/utils/page.js
index a17c6a2..2c57421 100644
--- a/lib/utils/page.js
+++ b/lib/utils/page.js
@@ -244,14 +244,15 @@ function normalizeHtml(src, options) {
.value();
var source = $(this).text();
- var html = options.book.template.applyBlock("code", {
+ var blk = options.book.template.applyBlock("code", {
body: source,
kwargs: {
language: lang
}
- }).body;
+ });
- $(this).html(html);
+ if (blk.html === false) $(this).text(blk.body);
+ else $(this).html(blk.body);
});
// Replace glossary terms