score:3

Accepted answer

You can tighten up the nodes by modifying the link distance and strength. The default distance value is 30 and the default strength is based on the number of nodes the source or target of a link connect to (source).

d3.forceLink().id(function(d) {
  return d.id;
}).distance(5).strength(1)

Related Query

More Query from same tag