Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

touch-events

Package Overview
Dependencies
Maintainers
1
Versions
6
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

touch-events

Touch events using PEP

  • 0.0.4
  • npm
  • Socket score

Version published
Weekly downloads
11
decreased by-35.29%
Maintainers
1
Weekly downloads
 
Created
Source

Touch Events

Touch Events on PEP.

Usage

Using JSPM (ECMAScript / ES6 Module)

Install the library.

jspm install touch-events=github:casperlamboo/TouchEvents

Include the library.

import touchEvents from 'touch-events';

Using NPM (CommonJS module)

Install the library.

npm install touch-events

Include the library.

var touchEvents = require('touch-events');

API

createListener

eventListener:EventDispatcher = touchEvents.createListener(DOMNode)

addEventListener

// gesture regonizers
eventListener.addEventListener('wheel', callback: Function);
eventListener.addEventListener('tap', callback: Function);
eventListener.addEventListener('dragstart', callback: Function);
eventListener.addEventListener('drag', callback: Function);
eventListener.addEventListener('dragend', callback: Function);
eventListener.addEventListener('seconddragstart', callback: Function);
eventListener.addEventListener('seconddrag', callback: Function);
eventListener.addEventListener('seconddragend', callback: Function);
eventListener.addEventListener('multitouchstart', callback: Function);
eventListener.addEventListener('multitouch', callback: Function);
eventListener.addEventListener('multitouchend', callback: Function);

// original touch events
eventListener.addEventListener('pointerdown', callback: Function);
eventListener.addEventListener('pointermove', callback: Function);
eventListener.addEventListener('pointerup', callback: Function);

setConfig

touchEvents.setConfig(config: Object)

config = {
  DRAG_THRESHOLD: Number = 10;
}

FAQs

Package last updated on 29 Mar 2017

Did you know?

Socket

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
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc