1.0.8 • Published 11 months ago
@jgtools/jgmath v1.0.8
JGMath
Math utils
Installation
Using npm
npm i @jgtools/jgmath// import all functions using a namespace
import * as JGMath from "@jgtools/jgmath";
// or import functions individually
import { getAngle } from "@jgtools/jgmath";
// ...Using cdn
<script type="module">
// import all functions using a namespace
import * as JGMath from "https://cdn.jsdelivr.net/npm/@jgtools/jgmath@1.0.7/dist/index.min.js";
// or import functions individually
import { getAngle } from "https://cdn.jsdelivr.net/npm/@jgtools/jgmath@1.0.7/dist/index.min.js";
// ...
</script>Usage
import { getAngle } from "@jgtools/jgmath";
const p1 = { x: 1, y: 2 };
const p2 = { x: 5, y: 5 };
const a = getAngle(p1, p2);License
MIT