Skip to content

How to reinitialize the bs5treeview? #5

@mahesh-tier1app

Description

@mahesh-tier1app

Hi,

On my page, I have more than one button. When I click on each button, I need to load the data in the tree view. When I click on any button the very first time then it works fine but after that, if I click on any other button then the data is not loading in a tree.

<div id="tree"></div>

// Assume I am calling the below function whenever any button is clicked
function showTreeView() {
     
     $('#tree').empty();
     $('#tree').bstreeview({ 
           data: getTreeData()
     });
}

Can you please let me know how can I reinitialize the tree?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions