Advertisement
Guest User

Untitled

a guest
Jul 22nd, 2017
51
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.39 KB | None | 0 0
  1. extension UITableView {
  2. func reusableCell(style: UITableViewCellStyle, reuseIdentifier: String, configureBlock: ((UITableViewCell) -> Void)? = nil) -> UITableViewCell {
  3. if let cell = dequeueReusableCell(withIdentifier: reuseIdentifier) {
  4. configureBlock?(cell)
  5. return cell
  6. }
  7. return UITableViewCell(style: style, reuseIdentifier: reuseIdentifier)
  8. }
  9. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement