HTML Elements Forums Data Grid Slow Smart-Grid creation

Tagged: ,

This topic contains 1 reply, has 2 voices, and was last updated by Avatar admin 2 months, 4 weeks ago.

Viewing 2 posts - 1 through 2 (of 2 total)
  • Author
    Posts
  • #101673
    Avatar
    chips
    Participant

    Is it normal for emtpy smart-grid creation to take between 2 and 7 or 8 seconds depending on the device?

    eg:

    createGrid()
    {
    Smart(this.domGrid, class
    {
    get properties()
    {
    return {
    sorting: { enabled: true },
    editing: {
    enabled: false,
    batch: false,
    mode: ‘row’
    },
    filtering: {
    enabled: true,
    filterMenu: { visible: true }
    },
    layout: {
    rowHeight: 25,
    rowMinHeight: 25
    },
    selection: {
    enabled: true,
    mode: ‘one’,
    allowCellSelection: true,
    allowColumnHeaderSelection: false
    },
    appearance: {
    placeholder: “empty”,
    showRowLines: false
    },
    behavior: {
    columnResizeMode: ‘growAndShrink’,
    allowColumnAutoSizeOnDoubleClick: true
    },
    dataSource: new Smart.DataAdapter({
    dataSource: {},
    dataFields: [
    ‘field1: string’,
    ‘field2: string’,
    ‘field3: string’,
    ‘field4: string’,
    ‘field5:number’,
    ‘field6:string’,
    ‘field7:number’,
    ‘field8:number’,
    ]
    }),
    columns: [

    { label: ‘field1’, dataField: ‘field1’, allowEdit: false },
    { label: ‘field2’, dataField: ‘field2’, allowEdit: true, width: “35%” },
    {
    label: ‘field3’,
    dataField: ‘field3’,
    allowEdit: true,
    showActionButton: false,
    editor: ‘numberInput’,
    cellsFormat: ‘F2’,
    cellsAlign: ‘right’,
    },
    { label: ‘field4’, dataField: ‘field4’, allowEdit: true, showActionButton: false },
    { label: ‘field5’, dataField: ‘field5’, allowEdit: true, showActionButton: false },
    {
    label: ‘field6’,
    dataField: ‘field6’,
    allowEdit: true,
    showActionButton: false,
    cellsAlign: ‘right’,
    editor: ‘numberInput’,
    cellsFormat: ‘F2’,
    formatFunction: function (settings) { if (!settings.value) settings.value = 2 },
    validationRules: [{ type: ‘max’, value: 100 }, { type: ‘min’, value: 0 }]
    },
    { label: ‘field8’, dataField: ‘field8’, allowEdit: false, width: “10%” }
    ]

    };
    }
    });

    #101674
    Avatar
    admin
    Keymaster

    Hi chips,

    1-2s is the current loading time of the Grid on desktop. This is for various data sets due to the virtualization the component creates only the necessary HTML elements and reuse them.

    Best regards,
    Peter Stoev

    Smart UI Team
    https://www.htmlelements.com/

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

You must be logged in to reply to this topic.