Jeremy
Jeremy

Reputation: 474

How to have multiple columns in tableview or alternative view?

I would like to replicate a similar type of list view with filterable header as the following images show from coingecko and coinmarketcap ios apps:

enter image description here

I found a github package called Swiftdatatables that appears to do the same function, but is there a way to replicate this without using any 3rd party items?

I attempted to recreate it with a stackview as the filterable header and a tbleview for the rows, but I do not see how it is possible to keep the tableview cell labels inline with the header columns?

My second though was they used a collectionview for the rows, but the layout feels more like a tableview? I am unsure on what the best way to create a similar view is.

Thanks

Upvotes: 0

Views: 1521

Answers (1)

Ryan Haycock
Ryan Haycock

Reputation: 73

They will most likely have used a UITableView with custom UITableView cells.

Using an XIB (nib) view to create the UI for a row and then passing the data in.

Check out here and here for more info.

Upvotes: 1

Related Questions