https://coroutinedispatcher.github.io/coroutinedispatcher/images/stavro.jpg

The Android guy

My first remote experience

typealias Coroutine = Quarantine I hope you get the joke…. Well, it has been a very rough year for me, “motion-ally” and emotionally. I moved to Germany just when all these corona fear started. Luckily I got time to get introduced to the team and the project and got ready to start fresh . And then, since the situation with the epidemic wasn’t getting any better, the company decided to switch to home office.

Getting rid of the white screen on the app start up

Details matter especially when it comes to making users happy. We have all kinds of users, those who don’t care how the app is designed (just do what he/she needs), those who care, and those who are developers themselves. I have met people who don’t use a single app just because it has some strange animation, and they hate it. For me, it’s a little from both. I Like seeing a minimalist design (like Airbnb Android app, which is one of my favorites, for instance), but it is also important to fulfill your needs also.

Generate Kotlin Docs using Dokka

Have you ever generated Kotlin docs (Kdocs) for your library/project? I have. There is a tool for this called Dokka and you can find it here. It’s not too hard to set up. I personally used Dokka for a small API i wrote for SharedPreferences. Anyways, the steps are pretty basic. One thing you must be careful though, is to know the syntax of the Kdocs pretty well (usually, if you know how to generate Javadoc, Kotlin docs don’t have much difference).

What I learned from Kotlin Flow API

I used to check the docs and just read a lot about flows but didn’t implement anything until yesterday. However, the API tasted really cool (even though some operations are still in Experimental state). Prerequisites: If you don’t know RxJava it’s fine. But a RxJava recognizer would read this faster. Cold vs Hot streams Well, I really struggled with this concept because it is a little bit tricky. The main difference between cold and hot happened to be pretty simple: Hot streams produce when you don’t care while in cold streams, if you don’t collect() (or RxJava-s equivalent subscribe()) the stream won’t be activated at all.

Searchable Fragments with the Paging Library

This post is inspired by @EpicPandaForce¬†answer in StackOverflow. I faced the same problem which I didn’t know how to solve: How to perform search when you are using a Paging Library (or how the hell to refresh after I reperform Rooms query)? Let’s suppose we have this scenario: I have a list of data, which are shown in the Fragment by LiveData observation, which are retrieved by the ViewModel through LiveDataPagedListBuilder().

Prepopulate Room with data.

There are times, when we just need the data when the app starts, and all the functionality is just a matter of work. Or we just need the app to be independent from the network and we have the data. A simple dog-race database or cat-race database doesn’t actually need online interaction at all (if there are not too many data of course). So, Room comes with a nice solution about this.