Socket
Socket
Sign inDemoInstall

@hackkun/touch

Package Overview
Dependencies
0
Maintainers
1
Versions
7
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

    @hackkun/touch

手势库


Version published
Weekly downloads
8
increased by700%
Maintainers
1
Install size
12.9 kB
Created
Weekly downloads
 

Readme

Source

@hackkun/touch

手势库,支持移动端和 PC 端,只支持 import 方式引用

介绍

  • 移动端事件:start end tap singleTap doubleTap longTap drag swipe pinch rotate
  • PC 端事件:start end tap singleTap doubleTap longTap drag swipe wheelStart wheel wheelEnd
  • 自定义 event 扩展了:
    • drag 下 deltaX,deltaY
    • swipe 下 Left Right Up Down
    • wheel 和 pinch 下 ratio

使用

import { HackTouchMobile, HackTouchPc } from '@hackkun/touch'
const ht = new HackTouchMobile(idName)
ht.on(EventName, (Event) => {})

Keywords

FAQs

Last updated on 29 Sep 2020

Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc