Skip to content

Instantly share code, notes, and snippets.

@pzmudzinski
Created November 14, 2018 21:43
Show Gist options
  • Save pzmudzinski/066c78a8515d8a332508c9a22f710638 to your computer and use it in GitHub Desktop.
Save pzmudzinski/066c78a8515d8a332508c9a22f710638 to your computer and use it in GitHub Desktop.
struct SectionOfBooks {
var header: String?
var items: [Book]
}
func createDataSource() -> RxTableViewSectionedAnimatedDataSource<SectionOfBooks> {
return RxTableViewSectionedAnimatedDataSource(
configureCell:{ (ds, tableView, indexPath, book) in
let cell = tableView.dequeueReusableCell(...)
cell.textLabel?.text = book.title
return cell
}
)
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment