contentLabel.preferredMaxLayoutWidth = kScreenWidth - 20
contentLabel.numberOfLines = 0
I use SnapKit to set top and left.
contentLabel.snp.makeConstraints { (make) in
make.top.equalTo(topView.snp.bottom)
make.left.equalTo(topView.iconView)
}
print(contentLabel.frame.size.height)
It prints 0. Does it all right?