Skip to content

Instantly share code, notes, and snippets.

@e-mihaylin
Created July 10, 2018 14:29
Show Gist options
  • Save e-mihaylin/a50d46546a717b207ff1abbe06d9adfb to your computer and use it in GitHub Desktop.
Save e-mihaylin/a50d46546a717b207ff1abbe06d9adfb to your computer and use it in GitHub Desktop.
const angle = (a, b, c ,d) => ~~((Math.atan2(d - b, c - a)) * 180 / Math.PI);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment