cytoscape / cytoscape.js-dagre

The Dagre layout for DAGs and trees for Cytoscape.js
MIT License
249 stars 83 forks source link

Organize only new object added to canvas #24

Closed calebeaires closed 7 years ago

calebeaires commented 7 years ago

I am using this plugin to organize elements on canvas box. I am using it with the code below.

            const layout = this.cy.layout({
                name: 'dagre',
                directed: true,
                rankDir: 'LR',
                fit: false
            });
            layout.run();

This will apply dagre on ever object on the cytoscape canvas. I would like use the cytoscape.js-dagre function that apply dagre layout only on specific elements (recently added).

maxkfranz commented 7 years ago

http://js.cytoscape.org/#eles.layout

Please ask how-to questions to stack overflow in future