Fork me on GitHub

Example: Basic jsontreeinspector field creation

How to create a jsontreeinspector field.

Basic JsonTreeInspector creation

HTML content

HTML

<div id="field-container"></div>

JavaScript

Implementation

YUI().use('inputex-jsontreeinspector', function(Y) {
   

   // Example 1
   new Y.inputEx.widget.JsonTreeInspector('container1', {inputEx: Y.inputEx, Global: window});


   // Example 2
   var obj = {
      content: "<div><b>yeah</b></div>"
   };
   new Y.inputEx.widget.JsonTreeInspector('container2', {htmlContent: obj});

});