Render valid JSON in samples (quoted object keys)

This commit is contained in:
Roman Hotsiy 2016-08-12 20:01:43 +03:00
parent 9aea9bc683
commit 0b46186585
No known key found for this signature in database
GPG Key ID: 5CB7B3ACABA57CB0

View File

@ -82,7 +82,7 @@ function objectToHTML(json) {
key = keys[i];
hasContents = true;
output += '<li><div class="hoverable ' + collapsed + '">';
output += '<span class="property">' + htmlEncode(key) + '</span>: ';
output += '<span class="property">\"' + htmlEncode(key) + '"</span>: ';
output += valueToHTML(json[key]);
if (i < length - 1) {
output += ',';