UNPKG

zrender

Version:

A lightweight graphic library providing 2d draw for Apache ECharts

10 lines (8 loc) 170 B
const PI2 = Math.PI * 2; export function normalizeRadian(angle: number): number { angle %= PI2; if (angle < 0) { angle += PI2; } return angle; }