セクションを2つ用意し、セクション0にはサイズを確定したセルを1つ配置し、セクション1にはサイズを可変にしたセルを複数表示したいのですが、うまく行きません。
以下のような記述をしています。
class TableView: UITableView, UITableVIewDelegate, UITableViewDataSource { override init(frame: CGRect, style: UITableViewStyle) { self.estimatedRowHeight = 90 rowHeight = UITableViewAutomaticDimension } //セルの高さ func tableView(tableView: UITableView, heightForRowAtIndexPath indexPath: NSIndexPath) -> CGFloat { if indexPath.section == 0 { return 200 } else { return 85 } } }
バッドをするには、ログインかつ
こちらの条件を満たす必要があります。