vue-shortcut-key
v0.0.1
Published
A keyboard shortcut instruction plugin for vue
Downloads
3
Maintainers
Readme
vue-shortcut-key
A keyboard shortcut instruction plugin for vue| 一个用于vue的键盘快捷键指令插件
Install
$ npm i vue-shortcut-key
# or
$ yarn add vue-shortcut-key
Usage
import Vue from 'vue'
import vueShortcutKey from 'vue-shortcut-key'
Vue.use(vueShortcutKey)
<template>
<div v-sk="handleMethod">
Press `ctrl + c` to continue.
</div>
</template>
<script>
export default {
data () {
return {
show: true
}
},
methods: {
handleMethod () {
do something...
}
}
}
</script>