sroze/ngInfiniteScroll — pull request #103 by gbockus (2014-07-07 03:13:34+00:00)
Title: Added an infiniteScrollAlternateTrigger attr to the directive that allow...

...s the loading to be trigger be a scope variable. This is to work around the issue where your app is located inside an iframe and the container can not be analyzed in order to determine if more data should be loaded.

This change was driven by the case where my app lives inside some number of iframes (salesforce app). The only view I have into have far the user has scrolled is via a event that fires providing the current sizing and scroll position. I use that event to drive the alternate trigger. I think this could be useful in other situations as well.

I still need to run a local server to verify that the usual means of running the infinite scroll works as expected. I tried created a test on plunkr, jsfiddle, and codepen.io, but all failed due to the iframe issue (I'm assuming).

Here is a plunkr of the simple demo using the alternate trigger.
http://plnkr.co/edit/dlwYrj