block by herrstucki 7c648f0d401cb283d09fd37a61e1a9c7

Draggable Blob II

Full Screen

Drag the blob to deform it. Press the shift key to show the underlying force simulation’s nodes and links.

Uses d3-shape‘s line() and curveBasisClosed() functions to draw a blob from a graph.

This version tries to prevent the blob from collapsing using polygonHull() but this results in the removal of points and leads to jumpiness (you see the dragged point getting removed when you hold the shift key and drag it inside the blob). See the version without it for smoother dragging.

index.html