I am trying to use a custom UiCollectionViewLayout, but I have a little problem. In my project, I want to load some JSON information and present it in a UICollectionView. I need to download information from WEB, and then (when everything is loaded) I need to reload my Collection View. If I use UICollectionViewFlowLayout
, everything will be fine. However, when I try to use my own layout, reloadData
does not work correctly and nothing happens.
I reload the data using async task:
dispatch_async(dispatch_get_main_queue(), ^{ [self.newsCollectionView reloadData]; });
thanks
source share