vue-lazyload-images
A plugin of lazy-load images for Vue2.x
Support images lazyload in window or build-in element.
Demo
Installation
npm
$ npm install vue-lazy-images
or
script
Usage
Entry.js
;Vue
Template
Options
Vue.use(VueLazyImage,options)
key | description | default | type |
---|---|---|---|
offset | offset distance for pre-loading | 0 | Number |
events | events that you want parentNode listen for | ['scroll', 'wheel', 'mousewheel', 'resize', 'animationend', 'transitionend', 'touchmove'] | Array |
throttle | spacing interval of continuous calling | 0(ms) | Number |
debounce | idle time between two actions | 0(ms) | Number |