Yet another Easings library for JS (ES2015+).
yarn add @j0hnm4r5/easings
Easings always takes a value from 0...1 and returns a number from 0...1 (except for Elastic
— those numbers may return outside the range).
import { Easings } from "easings";
Easings.easeInOut(7)(0.5); // generic easing funcions; the first number is the function order
Easings.easeInQuart(0.5); // everything else
- Example diagrams here: https://easings.net/
- Based on the conversations here: https://gist.github.com/gre/1650294
MIT © John Mars