Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Update math.js to include min, max, and clamp functions
Include of simple math helpers for inline calculations. All support Number types of Int and Float, but not edge case numbers such as NaN, +-infinity, or undefined. Min: given `A` and `B` return the smaller of the two on a standard number line. Max: given `A` and `B` return the larger of the two on a standard number line. Clamp: given `test`, `min` and `max` return the tested value if it falls within the range of `min` and `max` such that `min < test < max` is satisfied on a standard number line. If the constraint is not satisfied, return the closest bounding constraint.
- Loading branch information