I've been searching for answers about how to achieve this, but I'm getting a little lost.
I want to show data tables in my app, but not in the way that Apple's TableView does; rather, I want them to look more like Excel or HTML tables. Additionally, I'll have numerous tables like this on different pages of my app that I want to style uniformly, even if they won't all have the same number of rows or columns. Those tables might be shown on the screen along with pictures or text, but hardly ever by themselves. (I thus require a component I can include in a UIViewController)
Essentially, a table similar to this (I put this off Google Images because my data is confidential)
I have a theory on how to do this but I'm not sure it's right or exactly how to do it.
My theory is I should create a subclass of UICollectionView, let's call it MyTablesView. MyTablesView would have a variable named data. My pages/VC that contain a table will have an instance of MyTablesView and feed it data in this variable. MyTablesView takes care of styling and displaying this data.
So I guess my question is: How do I subclass a UICollectionView properly to display the data that will be given to it by a ViewController?