Skip to content

eles.targets()

eles.targets — Collection > Traversing > Incidence and neighbourhood. Cytoscape.js signatures, parameters and return contract.

eles.targets — Collection › Traversing › Incidence and neighbourhood

Preview · Collection › Traversing › Incidence and neighbourhood

Read in the complete API reference · All API members

// The target nodes of every edge in the collection, deduped
eles.targets(): Collection<NodeData, EdgeData, NodeData>

The target nodes of every edge in the collection, deduped.

Returns Collection<NodeData, EdgeData, NodeData>

the target nodes

Example

console.log(eles.targets().map(ele => ele.id())); // ["b","c"]

Example graph and handle setup