Oh how I loved kotlin-android-extensions and synthetic binding when it came out! I bet you liked that too. Unfortunately after some time android world realised, that this solution is not as perfect as we initially though and we need to migrate to jetpack view binding, or some other solution of your choice. While I was… Czytaj dalej Migration from synthetic binding
Autor: admin
Room database migrations
If you need to migrate you Room database, just follow this article:https://rahul9650ray.medium.com/room-db-migrations-in-android-cb165954ee6d
Plant a tree with Timber logs
If you want to log something in your debug app, and you for sure want, then you most probably heard about Timber library. It’s one of the most popular Android libraries, simple to use, but quite powerful. This is how you can make a basic setup, to logs messages only in debug build:
Gradient background for a view
If you still haven’t switch to Jetpack Compose, and you create your layout in XMLs you may wonder, how to create great looking gradient background for a View. Here’s the quick guide. Create new xml file under your drawables, like my_gradient_background.xml. It has to have few proprieties like: Play around to see what effect you… Czytaj dalej Gradient background for a view
SOLID principles
If you have been through at least one software engineering interview in your life chances are, that you were asked about SOLID principles. What they are, and how you can include them in your projects? Here’s the short sum up. SOLID is a term created by so called Uncle Bob, so for the real world… Czytaj dalej SOLID principles
Most common git commands
If you are like me, you like using git in the terminal. Here are few absolutely essential git commands I use everyday. git checkout -b somebranch # start working on a branchgit commit -am 'conquered the world’ # add and commit your changesgit push origin HEAD # create PR in your remotegit fetch+ git rebase… Czytaj dalej Most common git commands
Recognise if the device use HMS
If you are the unlucky one who need to handle new Huawei devices at your work or/and for your application, then you probably know, that HMS stands for Huawei Mobile Services (and GMS for Google Mobile Services). Sooner or later, you will want to recognise, what services are running on your user’s device. To do… Czytaj dalej Recognise if the device use HMS
Style your TextView with HTML tags
If you ever wondered if you can style your text with HTML tags – you absolutely can. For most cases it is enough to use Html.fromHtml or you can use it directly in your string resources. Here are the most used tags: Bold: <b>, <em> Italic: <i>, <cite>, <dfn> 25% increase in text size <big> 20% decrease in text size <small> Setting… Czytaj dalej Style your TextView with HTML tags
Data messages from FCM
If you want your app to handle push notification even if it is in background, or you simply need „silent push”, you need to use data message. Basically there are two types of payloads – notification, which will be visible for the user, and data which will be not visible. For data messages you have… Czytaj dalej Data messages from FCM
Debug notification
If you wonder how you can debug your notification coming from Firebase, when your app is not running here’s the answer.