Dynamic Height Issue for UITableView Cells (Swift)

前端 未结 25 2640
温柔的废话
温柔的废话 2020-11-28 04:39

Dynamic text of variable length are being injected into tableview cell labels. In order for the tableview cells\' heights to be dynamically sized, I have implemented in

25条回答
  •  醉话见心
    2020-11-28 05:11

    I had also got this issue initially, I had resolved my issue from this code try avoiding the use of self.tableView.reloadData() instead of this code for dynamic height

    [self.tableView reloadSections:[NSIndexSet indexSetWithIndex:0] withRowAnimation:UITableViewRowAnimationFade];
    

提交回复
热议问题