Skip to content

v1.12.4

Compare
Choose a tag to compare
@cheton cheton released this 12 Aug 10:00
· 75 commits to master since this release

Adds an optional complete callback to the next function of the loadNodes option (62b11af)

loadNodes: (parentNode, next) => { // Load node on demand
    // Loading...
    const nodes = [];
    nodes.length = 1000;
    for (let i = 0; i < nodes.length; ++i) {
        nodes[i] = {
            id: `${parentNode.id}.${i}`,
            name: `${parentNode.name}.${i}`,
            loadOnDemand: true
        };
    }

    next(null, nodes, function() {
        // Complete callback
    });
}