Created
November 27, 2016 12:50
-
-
Save kiroskirin/1914768303014ea6302854db3f9dac57 to your computer and use it in GitHub Desktop.
iOS : UITableView - Remove separator for last table view cell
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Remove sperator for last table view cell | |
override func tableView(_ tableView: UITableView, willDisplay cell: UITableViewCell, forRowAt indexPath: IndexPath) { | |
if indexPath.row == self.stations.count - 1 { | |
cell.separatorInset = UIEdgeInsets(top: 0, left: 0, bottom: 0, right: tableView.bounds.width) | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment