Javascript jQuery EasyUI插件以编程方式实例化

Javascript jQuery EasyUI插件以编程方式实例化,javascript,jquery,jquery-easyui,Javascript,Jquery,Jquery Easyui,我需要以编程方式实例化easyUI propertygrid并将其附加到div。这应该很容易,但我对jQuery和easyUI不熟悉。试试这个 HTML <div> <table id="pg" class="easyui-propertygrid" style="width:300px"> </table> </div> 链接到 $('#pg').propertygrid({ url:'path/to/json/file',

我需要以编程方式实例化easyUI propertygrid并将其附加到div。这应该很容易,但我对jQuery和easyUI不熟悉。

试试这个

HTML

<div>
  <table id="pg" class="easyui-propertygrid" style="width:300px">
  </table>
</div>
链接到

$('#pg').propertygrid({
   url:'path/to/json/file',
   showGroup:true,
   scrollbarSize:1
});