Is the following post still the accepted way of detecting when an instance of UITableView has scrolled to the bottom [in Swift], or has it been altered (as in: improved) sin
We can avoid using scrollViewDidScroll and use tableView:willDisplayCell
func tableView(_ tableView: UITableView, willDisplay cell: UITableViewCell, forRowAt indexPath: IndexPath) {
if indexPath.section == tableView.numberOfSections - 1 &&
indexPath.row == tableView.numberOfRows(inSection: indexPath.section) - 1 {
// Notify interested parties that end has been reached
}
}
This should work for any number of sections.