只需在初始化tableview时设置一下即可
tableview.estimatedRowHeight = 0;
tableview.estimatedSectionFooterHeight = 0;
tableview.estimatedSectionHeaderHeight = 0;
本文介绍如何通过设置UITableView的estimatedRowHeight, estimatedSectionFooterHeight和estimatedSectionHeaderHeight属性为0来优化Swift应用中的表格视图加载速度。
只需在初始化tableview时设置一下即可
tableview.estimatedRowHeight = 0;
tableview.estimatedSectionFooterHeight = 0;
tableview.estimatedSectionHeaderHeight = 0;
5761
339
2133

被折叠的 条评论
为什么被折叠?