vue拖动滚动条与拖拽冲突
Vue拖动滚动 (vue-dragscroll)
vue-dragscroll is a micro vue.js directive which enables scrolling via holding the mouse button ("drag and drop" or "click and hold" style).
vue-dragscroll是一个微型vue.js指令,可通过按住鼠标按钮(“拖放”或“单击并按住”样式)进行滚动。
安装 (Installation)
通过npm (Via npm)
$ npm install vue-dragscroll
Then, in your JavaScript file:
然后,在您JavaScript文件中:
// Register dragscroll globally
import VueDragscroll from 'vue-dragscroll'
Vue.use(VueDragscroll)
// Or, register it locally in a component
import { dragscroll } from 'vue-dragscroll'
export default {
name: 'MyComponent',
directives: {
'dragscroll': dragscroll
},
}