func tableView(_ tableView: UITableView, commit editingStyle: UITableViewCell.EditingStyle, forRowAt indexPath: IndexPath) {
guard editingStyle == .delete else {return}
datas.remove(at: indexPath.row)
tableView.deleteRows(at: [indexPath], with: .left)
}
'Programming > Swift' 카테고리의 다른 글
[Readable Coding Practice] How to make swiping view controller with swiping menu tab bar (0) | 2021.08.01 |
---|---|
[Readable Coding Practice] eliminate empty UItableView cells (0) | 2021.06.28 |
[Readable Coding Practice] Show and dismiss loading signals (0) | 2021.06.19 |
[Readable Coding Practice] UIScrollView Pagination (0) | 2021.06.19 |
[Readable Coding Practice] Image Caching (0) | 2021.06.19 |