UNPKG

@antv/coord

Version:

Toolkit for mapping elements of sets into geometric objects.

6 lines (5 loc) 177 B
export function adjustAngle(theta: number, min: number, max: number) { while (theta < min) theta += Math.PI * 2; while (theta > max) theta -= Math.PI * 2; return theta; }