@3r/tool
Version:
🏃包含一些常用方法例如对象深克隆、递归调用、一一对比/数组交集、并集、差集/二维向量点乘、叉乘/股票KDJ、MACD、RSI、BOLL/验证为空、车牌号、邮箱、身份证、统一社会信用代码、手机号、版本对比/转换日期、星座、身份证解析、字节/随机颜色、手机号、身份证号码、统一社会信用代码...持续更新整合
30 lines (28 loc) • 920 B
JavaScript
import { Animation } from "../index.js";
let description = function () {
return ["#### Animation 动画模块", "包含一些动画的方法.", "", "以下是相关示例:"];
};
let run = async function () {
// TODO 可以参考相关示例 34.抽奖页面
// https://linyisonger.github.io/H5.Examples/
};
try {
describe("动画模块", function () {
it("easeIn", function () {
expect(Animation.easeIn(0.5) < 0.5).toEqual(true);
expect(Animation.easeIn(100000) < 0.5).toEqual(true);
});
it("easeOut", function () {
expect(Animation.easeOut(0.5) > 0.5).toEqual(true);
});
it("ease", function () {
expect(Animation.ease(0.5) > 0.5).toEqual(true);
});
it("easeInOut", function () {
expect(Animation.easeInOut(0.5)).toEqual(0.5);
});
});
} catch (error) {
// describe is not defined 无需理会 调用方式不一致
}
export { run, description };