jQuery UI Widgets Forums TreeGrid JQXTree is loading slow with 500 records.

Tagged: 

This topic contains 1 reply, has 2 voices, and was last updated by  admin 1 year, 1 month ago.

Viewing 2 posts - 1 through 2 (of 2 total)
  • Author

  • Robin089
    Participant

    JQXTree is loading slow with 500 records. Below is my code snipset.

    It is taking around 3-4 seconds to load 500 records which is very slow as it is hampering my performance. Is there any alternative approch we can follow to reduce the binding time.

    var source = {
    datatype: “json”,
    datafields: [{ name: “ClassRid”, type: “int” }, { name: “ParentClassRid”, type: “int” }, { name: “ClassName”, type: “string” }, { name: “ClassLabel”, type: “string” }],
    id: “ClassRid”,
    localdata: dataSource,
    async: true,
    hasThreeStates: false
    };
    var dataAdapter = new $.jqx.dataAdapter(source);
    dataAdapter.dataBind();
    var records = [];
    if (dataSource.length > 0)
    records = dataAdapter.getRecordsHierarchy(“ClassRid”, “ParentClassRid”, “items”, [{ name: “ClassLabel”, map: “label” }, { name: “ClassRid”, map: “value” }, { name: “ClassName”, map: “ClassName” }]);

    $(“#treeId”).jqxTree({ checkboxes: true, source: records, width: ‘100%’, height: 220 });


    admin
    Keymaster

    Hi,

    jqxTree as a SEO friendly UI component which is usually used for website navigation requires to load all the HTML elements in the DOM and with many UI elements in a web page, the performance is affected. For loading large amounts of data, you can use jqxTreeGrid – https://www.jqwidgets.com/jquery-widgets-demo/demos/jqxtreegrid/javascript-tree-grid-virtual-mode.htm?fluent. jqxTreeGrid loads only the visible nodes and reuses the same set of HTML Elements.

    Regards,
    Peter

Viewing 2 posts - 1 through 2 (of 2 total)

You must be logged in to reply to this topic.