Skip to content

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Β 

History

1 Commit
Β 
Β 
Β 
Β 

Repository files navigation

Swipe Events helper

Init sample

const el = document.querySelector('.el')
const swipeEvents = new SwipeEvents(el)

function prev () {
  console.log('prev')
}

function next () {
  console.log('next')
}

el.addEventListener('swipeRight', prev)
el.addEventListener('swipeLeft', next)

Destroy sample

el.removeEventListener('swipeRight', this.prev)
el.removeEventListener('swipeLeft', this.next)
swipeEvents.removeEventListener()

About

Swipe Events helper πŸ› 

Resources

Stars

Watchers

Forks

Releases

Packages

Contributors

Languages