A JavaScript Library of math functions for 2D and 3D shapes.
Version 3.x.x
of this package is a rewritten version. I am not currently done, and if you want all of the feautues use the 2.5.0
version until further notice.
npm install shapemath-js
// With import statements.
import { line } from 'shapemath-js';
line.isParallel(0, 1, 2, 2, 0, 2, 2, 3);
// Without import statements.
const shapemath = require('shapemath-js');
shapemath.line.isParallel(0, 1, 2, 2, 0, 2, 2, 3);
You can read the documentation at https://shapemath-js.netlify.com/ to learn about all the functions.