block by mbostock 9b5a2fd1ce1a146f27e4

Pie Centroid

Full Screen

The black dots show the midpoint computed by d3-shape’s arc.centroid. Note that this is not the geometric center of the arc, which may be outside the arc; this method is merely a convenience for positioning labels.

Updated Example →

index.html