pointDistance
Calculates the pixel distance between two points.
Basic example
Section titled “Basic example”The straight-line (Euclidean) distance between two [x, y] points, in whatever units the coordinates use. A 160 by 120 offset gives the classic 200.
import {pointDistance} from "@d3plus/math";
pointDistance([40, 160], [200, 40]);
Parameters
import {pointDistance} from "@d3plus/math";