Skip to content

Instantly share code, notes, and snippets.

@fvilarino
Created April 19, 2021 20:35
Show Gist options
  • Save fvilarino/04a0cb53d9c900ab63b2422332c56ddb to your computer and use it in GitHub Desktop.
Save fvilarino/04a0cb53d9c900ab63b2422332c56ddb to your computer and use it in GitHub Desktop.
Viewholder item base class
interface Diffable {
val id: Long
}
interface RecyclerViewBindingItem : Diffable {
val type: Int
fun onCreateViewHolder(parent: ViewGroup, viewType: Int): RecyclerViewViewHolder<*>
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment