Skip to content

Instantly share code, notes, and snippets.

Created July 1, 2020 05:05
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
Star You must be signed in to star a gist
What would you like to do?
func tableView(_ tableView: UITableView, numberOfRowsInSection section: Int) -> Int {
return tableStructure.count
func tableView(_ tableView: UITableView, cellForRowAt indexPath: IndexPath) -> UITableViewCell {
let cellType = tableStructure[indexPath.row]
let cell = cellType.generator.cell(for: indexPath, inTableView: tableView)
cellType.generator.configure(cell: cell, using: cellType.associatedObject, at: indexPath)
return cell
func tableView(_ tableView: UITableView, heightForRowAt indexPath: IndexPath) -> CGFloat {
return tableStructure[indexPath.row].cellHeight
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment