Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
protected renderAdditionals(edge: SEdge, segments: Point[], context: RenderingContext): VNode[] {
const p1 = segments[segments.length - 2]
const p2 = segments[segments.length - 1]
return [
export function angle(x0: Point, x1: Point): number {
return toDegrees(Math.atan2(x1.y - x0.y, x1.x
- x0.x));
}
protected renderAdditionals(edge: DependencyGraphEdge, segments: Point[], context: RenderingContext): VNode[] {
const p2 = segments[segments.length - 1];
let p1: Point;
let index = segments.length - 2;
do {
p1 = segments[index];
index--;
} while (index >= 0 && maxDistance(p1, p2) < this.arrowLength);
return [