Vue dragscroll is a micro vue.js directive that enables scrolling by pressing the mouse button (“drag and drop” or “click and hold” style).
Ignore specific mouse buttons
You can use the following modifiers:
- noleft
- nomiddle
- noright
- noback
- forward
Must Read: Javascript Scroll Animation When An Element In View | OnScroll
How to make use of it:
Install & Download:
$ npm install vue-dragscroll
Install globally (main.js)
import { createApp } from 'vue' import { dragscrollNext } from "vue-dragscroll"; import App from './App.vue' const app = createApp(App); app.directive('dragscroll', dragscrollNext); app.mount('#app')
EVENTS
The directive provides 3 events.
- dragscrollstart
- dragscrollmove
- dragscrollend
See Also –
JavaScript Library To Make DOM Elements “Scroll To Show” | scrollShow.js
A Cross-Browser JavaScript Library to Disable Page Scrolling | scroll-lock
Change Web Sections to One Page Scrolling Effect In JavaScript Plugin | docSlider.js
See Demo And Download
Official Website(donmbelembe): Click Here
This superior jQuery/javascript plugin is developed by donmbelembe. For extra Advanced Usage, please go to the official website.