lazy scroll – infinite scrolling angularjs plugin
What is lazy scrolling?
lazy-scroll is a angularjs directive for infinite scrolling. Instead of click pagination links and going to next page , this will help to load data on scrolling as you can see in facebook .lazy-scroll will work with out jquery .
What you have to do to implement on angularjs project?
lazy-scroll is a a simple directive for angularjs application. Simply we have to call the function which you want to call for pagination in lazy-scroll attribute.
It will magically load data and append into variable when user reaching bottom of page. There are API also available to controll the behaviour.
Just see some demo samples.
Check out some Demo
demo with explanation can see here
How do I use in my project?
you can download the minified version or you can use the cdn and follow simple 3 steps
Step 1 :
Add script at bottom of page after angularjs
Ensure that your application module specifies lazy-scroll as a dependency.
var app = angular.module("yourModule",['lazy-scroll']);
Use the directive by specifying an lazy-scroll attribute on an element.
<div lazy-scroll="paginationFuntion()" lazy-scroll-trigger="80" >
That is it ! it will work like a magic
What is next?
Check our API from here
See some demo and implement 🙂
31,187 total views, 7 views today