Skip to content

Speeds up your clicks by combining the speed of pointerdown, and the features of the click event

License

Notifications You must be signed in to change notification settings

victrme/clickdown

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

21 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

clickdown

npmjs - demo

Speeds up clicks by combining the speed of pointerdown and the features of click in a single "clickdown" event.

It attaches the onclickdown function to Element and HTMLElement prototypes, which means you can use it with getElementById, querySelector, and others.

Like this:

import 'clickdown'

document.getElementById('my-input').onclickdown(function (event, target) {
  console.log(event)   // PointerEvent
  console.log(target)  // <input type="..." />
})

About

Speeds up your clicks by combining the speed of pointerdown, and the features of the click event

Topics

Resources

License

Stars

Watchers

Forks