[![CI Status](http://img.shields.io/travis/Twaha Mukammel/InfiniteScrollCollectionView.svg?style=flat)](https://travis-ci.org/Twaha Mukammel/InfiniteScrollCollectionView)
To run the example project, clone the repo, and run pod install
from the Example directory first.
Create a infinitely scrolling horizontal collection view.
- Total number of items in the collection view should sum to a width greater than or equal to width of collection view.
- There will be repeating (one less than number of elements occupy the collection view bounds.width -> N) elements on both ends of data source array. To the begning N elements will be added from the end and at the end N elements will be added from the begning. So in identifying the elements please use some mechanism.
- Add InfiniteScrollCollectionView in Storyboard or initWithFrame.
- Set 'infiniteScrollDelegate'.
- Call 'prepareDataSourceForInfiniteScroll' with data array.
- Call 'setInitialOffset' on viewDidAppear.
- Implement 'uniformItemSizeInCollectionView' of InfiniteScrollCollectionViewDelegatge.
- Call 'infiniteScrollViewDidScroll' from 'scrollViewDidScroll' of this collectionView's delegate.
Thats it. Enjoy!
InfiniteScrollCollectionView is available through CocoaPods. To install it, simply add the following line to your Podfile:
pod "InfiniteScrollCollectionView"
Twaha Mukammel, t.mukammel@aol.com
InfiniteScrollCollectionView is available under the MIT license. See the LICENSE file for more info.