I have a strange issue with FancyTree while doing lazy load the previous items are not getting cleared.
lazyLoad: function (event, data) {
data.node.removeChildren();
data.result = {
url: request_url + "?type=get"
};
}
The previous children are still there and new data is appending, however, in node.children method, I don't see them. Looks like the issue is with UI reload but not sure how to fix that.
Lazy nodes should not have children, just the
lazyattribute set.Only when the node is expanded for the first time, the
lazyLoad()callback gets called. Therefore there is no need to remove children.