Skip to content

Instantly share code, notes, and snippets.

@lukewakeford
Created September 4, 2019 14:49
Show Gist options
  • Save lukewakeford/8f0182b11894f918fc8809b9df26ce4d to your computer and use it in GitHub Desktop.
Save lukewakeford/8f0182b11894f918fc8809b9df26ce4d to your computer and use it in GitHub Desktop.
Hide the label first
func tableView(_ tableView: UITableView, cellForRowAt indexPath: IndexPath) -> UITableViewCell {
cell.rankLabel.isHidden = true
if let rank = list.rank {
cell.rankLabel.setTitle(title: rank, titleFont: UIFont.customBold!, colour: .white)
cell.rankLabel.isHidden = false
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment