Created by me in Figma

Originally published at:

Gradle scripts has been real mess for me since I started learning Android! Every time I create a new project, I would open another project and copy as much as I can from its Gradle scripts. I would find related code lines that I need and then copy them one by one. such a headache it is! But what if there’s a better way to manage all this? I’m not talking about Gradle extra properties. They are clumsy too. …

Created in Adobe XD by Birju Vachhani

Originally published at:

Howdy people! We have been using RecyclerView for such a long time. It seems pretty easy to implement, isn’t it? All we need to do is extend RecyclerView.Adapter class and implement at least 3 methods:

  • getItemCount()
  • onCreateViewHolder()
  • onBindViewHolder()

That’s it! After that generally, we provide a way to set data to adapter by adding a method like setList() and then in the method we assign a new list and then we call notifyDataSetChanged() to update RecyclerView.

But that’s not it. The method notifyDataSetChanged() refreshes whole list. As a result onBindViewHolder() is called for all of the items…

Early Introduction of Android ViewPager2

Originally published at:

It’s been a while since the alpha version of Android ViewPager2 is released by Google on 7th February 2019. You can find more information about the alpha release here. Let’s see what ViewPager2 brings to the table!

New Features

  • Right-to-left (RTL) layout support
  • Vertical Orientation Support
  • A Better PageChangeListener

What has been changed!

This version of ViewPager2 is released for Android X so if you want to use it then your project must have been migrated to Android X. Let’s see how we can use this new ViewPager2.

First Thing First: Gradle Dependency

Add following dependency to your…

When it comes to retrieve location in android devices, we see it as a tedious task as it requires a lot of boilerplate code. We need to handle android’s permission model for location permission and also we need to keep an eye for device’s location settings also.

Continue this article on my personal blog here.

Howdy people! Recently I was exploring the internet to get some guidance on publishing Flutter or Dart packages to via CI-CD servers. My primary goal was to use GitHub Actions to do so. Unfortunately 😕, I failed to get proper information on how can I achieve that. Then I decided to go by myself and I struggled a lot to get it working properly. So, I decided to write this easy and step-by-step guide to help others like me out there!

Continue this article on my personal blog here.

Are you a Flutter Developer? Do you use build_runner for code generation? Are you tired of typing or remembering the anaconda sized build_runner command? Do you want to get rid of that? Then you’ve come to the right place.

Almost every Flutter project uses code generation nowadays. Who wouldn’t? No one likes to write boilerplate code by themselves. It is exhausting and is kind of stupid at some point. That’s why Flutter developers love build_runner(Maybe not, I don’t know). The power you feel when you make the computer write code itself is incredible, isn’t it? But with great power comes great responsibility and it’s nothing different with build_runner.

Continue this article on my personal blog here.

Created in Adobe XD by Birju Vachhani

Developer community have tons of information to process after Google I/O’19 sessions. The session made it clear that it is going to be Kotlin first for Android. It covered the progress made in Android support for Kotlin and Kotlin-centered universe like Kotlin samples and reference docs, annotations, framework APIs, IDE support for low-level byte code optimizations in the D8/R8 compiler.

But besides all the big fancy things that got mentioned in the keynote, we are going to check out what’s new in android architecture components.

Originally posted at:

Data Binding is declarative UI inside XML. …

Jenkins with Android (Created in XD)

Originally published at:

Everything seems difficult until it is done!! I have been exploring Jenkins for a while now. When I started I didn’t know that I would face difficulty in doing the basic setup of Jenkins for building an Android project. Fortunately, I was able to make my way out after toiling for almost a week. Though Jenkins is easy to set up, it is not that easy when used for building Android Project. If you are also facing some problem, then read my post below to avoid difficulty in the setup of Jenkins for building Android project. …

Originally published at:

Howdy People 😄 ! Starting a blog was one of the things from my Things To Do-2018 list. If you are reading this right now then I guess it must have been into your wish list too. Like me, many people are confused about how to start a blog?, which service to us?, should it be self hosted or not? blah blah blah. Well, I have been to that phase too. So, today I’m going to help you out for starting a blog.

Why A Self Hosted Blog?

Many of you must have been thinking that why I have to host it…

Migrating Gradle Build Scripts to
Kotlin DSL

Originally published at:

Howdy people! It’s been a while since Gradle released support for Kotlin scripts. We have been writing Gradle script in a language called Groovy since ages. Let’s be honest, We all know that Groovy sucks! Half of the times I have been like this when there’s an issue:

Birju Vachhani

Google Certified Associate Android Developer | Flutter | Work @CodelesslyInc |

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store