dhotson / springy

A force directed graph layout algorithm in JavaScript
http://getspringy.com
MIT License
1.88k stars 240 forks source link

Node images #99

Closed yoooooooooooooooooooooooo closed 6 years ago

yoooooooooooooooooooooooo commented 6 years ago

Is it possible to use images for nodes, instead of labels??

dhotson commented 6 years ago

Yep, when creating a node give it an image property something like:

var node = graph.newNode({ image: { src: "http://...." }});

I think you can also set the width and height on it too..