Update data widget to display its content in JSON

This commit is contained in:
Jeremy Ruston 2024-05-06 15:34:42 +01:00
parent e378c6c4c9
commit 1d89c7925a
1 changed files with 4 additions and 1 deletions

View File

@ -31,7 +31,10 @@ DataWidget.prototype.render = function(parent,nextSibling) {
this.parentDomNode = parent;
this.computeAttributes();
this.execute();
this.renderChildren(parent,nextSibling);
var jsonPayload = JSON.stringify(this.readDataTiddlerValues(),null,4);
var textNode = this.document.createTextNode(jsonPayload);
parent.insertBefore(textNode,nextSibling);
this.domNodes.push(textNode);
};
/*