Home > @jsplumbtoolkit/core > Graph > addNodes
Graph.addNodes() method
Adds a list of Nodes to the Graph
Signature:
addNodes(data: Array<ObjectData>, idFunction?: IdFunction): void;
Parameters
Parameter | Type | Description |
---|---|---|
data | Array<ObjectData> | List of data objects, one for each Node to be added. |
idFunction | IdFunction | Optional function to use to retrieve ID from backing data. Defaults to retrieving id from data object. |
Returns:
void