升級iOS 11只有,發現
- (CGFloat)tableView:(UITableView *)tableView heightForFooterInSection:(NSInteger)section
tableView:(UITableView *)tableView heightForHeaderInSection:(NSInteger)section 。
這兩個方法失效了
這時候只需要設置tableView的幾個屬性即可
self.tableview.estimatedRowHeight = 0;
self.tableview.estimatedSectionHeaderHeight = 0;
self.tableview.estimatedSectionFooterHeight = 0;
親測有效