1.0.7 • Published 6 years ago

vue-tap-and-hold v1.0.7

Weekly downloads
89
License
MIT
Repository
github
Last release
6 years ago

vue-tap-and-hold

This is a lightweight vue2 plugin for Tap Event and Long Press Event in mobile

How To use

npm i vue-tap-and-hold --save
import TapAndHold form 'vue-tap-and-hold'
Vue.use(vueTap, {
	holdTime: 2000 // default is 1000
	tapTime: 200 // default is 200
})

You can also directly include it with a <script> tag

template

<!-- tap -->
<p v-tap="handle"></p> 

<!-- long press -->
<p v-hold="handle"></p> 

<!-- preventDefault -->
<p v-hold.prevent="handle"></p> 

<!-- stopPropagation -->
<p v-hold.stop="handle"></p> 

<!-- with params -->
<p v-tap="handle.bind(null, params)"></p> 
1.0.7

6 years ago

1.0.6

6 years ago

1.0.4

6 years ago

1.0.3

6 years ago

1.0.0-rc.5

6 years ago

1.0.0-rc.4

6 years ago

1.0.0-rc.3

6 years ago

1.0.0-rc.2

6 years ago

1.0.0-rc.1

6 years ago

1.0.2

6 years ago

1.0.1

6 years ago

1.0.0

6 years ago