Reputation: 307
I have been using my own solution for months. I developed it because I thought it is simple. But the code turned out to be quite clumsy and messy. So I gave up, but I can not found any good open source/community base module for that.
I love this one. https://binarymuse.github.io/ngInfiniteScroll/
Is there a way to add "show more" button to it ?
Upvotes: 1
Views: 1737
Reputation: 8465
You are using outdated documentation, this one is correct https://sroze.github.io/ngInfiniteScroll/documentation.html and what are you looking for is infinite-scroll-listen-for-event
<div infinite-scroll-listen-for-event='anEvent'></div>
<button ng-click="broadcastEvent()">Show More</button>
and then in controller
$scope.broadcastEvent = function () {
$scope.$broadcast('anEvent')
}
Upvotes: 1