vue-class-on-scroll
v0.1.0
Published
A powerful vue directive for adding class to an element on scroll.
Downloads
139
Readme
vue-class-on-scroll
A directive to add css class to the element for vue.js(2.x).
Install
npm install vue-class-on-scroll --save
Dev
run npm install
and npm run dev
Import
import ClassOnScroll from 'vue-class-on-scroll' // Es6 module
Use
directives: {
'class-on-scroll': ClassOnScroll,
},
<ELEMENT v-class-on-scroll="{ class: 'myClass', offset: 0 }">
</ELEMENT>