cmark

My personal build of CMark ✏️

Commit
b811dd8facd3fe26da32b93d70ab92d3693fab5c
Parent
7b43ae5be655259cc9081843b0e34e58bad37b72
Author
John MacFarlane <fiddlosopher@gmail.com>
Date

XMLRenderer -> XmlRenderer.

For consistency with HtmlRenderer. I'm not sure which is best.

Diffstat

3 files changed, 5 insertions, 5 deletions

Status File Name N° Changes Insertions Deletions
Modified js/bin/commonmark 2 1 1
Modified js/lib/index.js 2 1 1
Modified js/lib/xml.js 6 3 3
diff --git a/js/bin/commonmark b/js/bin/commonmark
@@ -36,7 +36,7 @@ var renderer;
 if (format === 'html') {
     renderer = new commonmark.HtmlRenderer(options);
 } else if (format === 'xml') {
-    renderer = new commonmark.XMLRenderer(options);
+    renderer = new commonmark.XmlRenderer(options);
 } else if (format === 'ast') {
     renderer = { render: function(node) {
                    return util.inspect(node.toAST(), null, 20, true) + '\n';
diff --git a/js/lib/index.js b/js/lib/index.js
@@ -14,4 +14,4 @@
 module.exports.Node = require('./node');
 module.exports.DocParser = require('./blocks');
 module.exports.HtmlRenderer = require('./html');
-module.exports.XMLRenderer = require('./xml');
+module.exports.XmlRenderer = require('./xml');
diff --git a/js/lib/xml.js b/js/lib/xml.js
@@ -120,8 +120,8 @@ var replaceUnsafeChar = function(s) {
 
 var reNeedsEscaping = /[&<>"]/;
 
-// The XMLRenderer object.
-function XMLRenderer(options){
+// The XmlRenderer object.
+function XmlRenderer(options){
     return {
         // default options:
         softbreak: '\n', // by default, soft breaks are rendered as newlines in HTML
@@ -143,4 +143,4 @@ function XMLRenderer(options){
     };
 }
 
-module.exports = XMLRenderer;
+module.exports = XmlRenderer;