any-touch
TypeScript icon, indicating that this package has built-in type declarations

2.2.0 • Public • Published

any-touch NPM Version NPM Downloads size-image codecov CircleCI

6类手势

  • 支持 PC 端 / 移动端 / 微信小程序.
  • 默认加载6 个手势, 也可按需加载手势, 核心1kb, 完整4kb.
  • 无依赖, 不限于 Vue / React / Angular等...

演示

查看二维码

直接访问

安装

npm i -S any-touch

CDN

<script src="https://unpkg.com/any-touch/dist/any-touch.umd.min.js"></script>
<script>
    console.log(AnyTouch.version); // 2.x.x
</script>

快速开始

import AnyTouch from 'any-touch';

const el = document.getElementById('box');
const at = new AnyTouch(el);

// e包含位移/速度/方向等信息
at.on('pan', (e) => console.log(e));

🚀 更多文档

Readme

Keywords

Package Sidebar

Install

npm i any-touch

Weekly Downloads

172

Version

2.2.0

License

MIT

Unpacked Size

146 kB

Total Files

12

Last publish

Collaborators

  • russell-ne