src/core/visual.js
function visualManager (records) {
    let nodes, node;

    records.forEach(record => {
        nodes = record.removedNodes;
        if (!nodes || !nodes.length) return;

        for (let i=0; i<nodes.length; ++i) {
            node = nodes[i];
            if (node.querySelectorAll) {
                if (!node.__visual__)
                    select(node).selectAll('.d3-visual').each(destroy);
                else
                    destroy.call(node);
            }
        }
    });
}
function visualManager (records) {
    let nodes, node;

    records.forEach(record => {
        nodes = record.removedNodes;
        if (!nodes || !nodes.length) return;

        for (let i=0; i<nodes.length; ++i) {
            node = nodes[i];
            if (node.querySelectorAll) {
                if (!node.__visual__)
                    select(node).selectAll('.d3-visual').each(destroy);
                else
                    destroy.call(node);
            }
        }
    });
}
function visualManager ( records ) { let nodes , node ; records . forEach ( record => { nodes = record . removedNodes ; if ( ! nodes || ! nodes . length ) return ; for ( let i = 0 ; i < nodes . length ; ++ i ) { node = nodes [ i ] ; if ( node . querySelectorAll ) { if ( ! node . __visual__ ) select ( node ) . selectAll ( '.d3-visual' ) . each ( destroy ) ; else destroy . call ( node ) ; } } } ) ; }
Clears visualisation going out of scope
Clears visualisation going out of scope