SmartRecyclerView — An android library for quick setup of RecyclerView

KUNAL PASRICHA
1 min readMay 18, 2021

--

Ever heard of Recyclerview being smart ?.
RecyclerView is the most common ViewGroup used to represents a list of items in Android applications.

If you’re new to Android Development or RecyclerView in Android I would recommend you to go through this article.

This idea of creating a SmartRecyclerView originates since every time I need to use a RecyclerView, even for small listing applications , I end up rewriting the same boilerplate code again and again, so I decided to create a simple generic adapter that simplifies things for me.

Source code and demo is available on GitHub here, so get it and have a look if you want to know more about the internals, I’ll just show you how to use it in your android application.

Let’s do it quickly!

allprojects {
repositories {
maven { url 'https://jitpack.io' }
}
}


buildFeatures {
dataBinding = true
}


dependencies {
implementation 'com.github.Kunalapk:SmartRecyclerView:1.92'
}

Here is the activity_main.xml

MainActivity.kt

Sign up to discover human stories that deepen your understanding of the world.

Free

Distraction-free reading. No ads.

Organize your knowledge with lists and highlights.

Tell your story. Find your audience.

Membership

Read member-only stories

Support writers you read most

Earn money for your writing

Listen to audio narrations

Read offline with the Medium app

--

--

No responses yet

Write a response