aboutsummaryrefslogtreecommitdiff
path: root/dingus.html
diff options
context:
space:
mode:
authorJohn MacFarlane <fiddlosopher@gmail.com>2015-01-11 14:54:02 -0800
committerJohn MacFarlane <fiddlosopher@gmail.com>2015-01-11 14:54:02 -0800
commit7b43ae5be655259cc9081843b0e34e58bad37b72 (patch)
treea762e4d2efe041e05a31f3691183e5105dd3be76 /dingus.html
parent11a7287be0f5040f4cff4415466d04604b7b5015 (diff)
Updated dingus to use XML for the AST pane.
Diffstat (limited to 'dingus.html')
-rw-r--r--dingus.html3
1 files changed, 2 insertions, 1 deletions
diff --git a/dingus.html b/dingus.html
index b0b6b32..f3fded4 100644
--- a/dingus.html
+++ b/dingus.html
@@ -10,6 +10,7 @@
<script type="text/javascript">
var writer = new commonmark.HtmlRenderer();
+var xmlwriter = new commonmark.XMLRenderer({ sourcepos: true });
var reader = new commonmark.DocParser();
function getQueryVariable(variable) {
@@ -57,7 +58,7 @@ $(document).ready(function() {
var renderTime = endTime - startTime;
$("#preview").html(result);
$("#html").text(result);
- $("#ast").text("UNDER CONSTRUCTION"); // TODO - replace with xml
+ $("#ast").text(xmlwriter.render(parsed));
$("#rendertime").text(renderTime);
};
var parseAndRender = function() {