72 Topics
|
|
## Introduction ## WorkManager is the preferred method of managing background tasks on Android. It also includes convenient extensions for RxJava3 and Kotlin Coroutines. In this tutorial, we will learn how to use WorkManager as well as how to observe the background task with the debugging tool Background Task Inspector. … |
|
## Introduction ## Coil is a popular image loading library for Kotlin-first Android projects. It is lightweight, fast and is super easy to use. In this tutorial, we will learn how to use Coil to load images into our project. ## Goals ## At the end of the tutorial, you … |
|
## Introduction ## In this tutorial, we will learn how to capture a picture with the new **ActivityResult** APIs(`androidx.activity.result`), which replace the `startActivityForResult()` and `onActivityResult()` APIs(*from Activity class*). Additionally, we will also learn about the ContentProvider **FileProvider**, which we will have to set up to save our images. ## Goal … |
|
## Introduction ## Navigation component is an abstraction on top of FragmentManager, which simplifies navigation between fragments. In this tutorial, we will learn how to use the Navigation component in our App. ## Goal ## At the end of the tutorial, you would have learned: 1. How to use the … |
|
## Introduction ## Regardless of whether you like notches on your devices or not, they exist, so as developers, we will have to adapt our Apps to work with them. In this tutorial, we will learn how to adapt our code to work with notches. The device used in this … |
|
## Introduction ## If your Android app is available to a global audience, you might have wondered how to load localized **String**s into your app. This tutorial will teach you how to do just that. There are quite a few steps involved, but once you understand the concepts, it will … |
|
## Introduction ## If you are a Java developer coming to Kotlin, you might have wondered how to use a language construct that is similar to the try-with-resource statement in Java to automatically close Autocloseable/Closeable resources for you. Luckily, Kotlin provides the inline extension function `use()` that provides similar functionality … |
|
## Introduction ## In Kotlin, we can extend classes without subclassing via extension functions and extension properties. This feature is useful whenever we want to extend 3rd party libraries or final classes. In this tutorial, we will learn what extension functions and extension properties are, and how to create our … |
|
## Introduction ## `launch()` and `async()` are two of the most common coroutine builders to use in Kotlin, but they are somewhat different in usage. `launch()` returns a `Job` object, which can be used to cancel or perform other operations on the underlying coroutine. If our coroutine lambda returned a … |
|
## Introduction ## With coroutines in Kotlin, we are able to execute suspending functions without blocking the current thread. By default, most coroutine builder functions use the `Dispatchers.Default` context, but it is also possible to use other implementations of `CoroutineContext`. In this tutorial, we will learn about the 2 `CoroutineDispatchers`: … |
|
## Introduction ## In Android development, the current recommended library for Dependency Injection is Hilt. The most obvious benefits of using Hilt are reduced boilerplate code and lifecycle-aware components(*and their associated annotations*). Hilt is a great library, but it is not perfect. Hilt is built on top of Dagger 2, … |
|
## Introduction ## This tutorial teaches you how to implement the Type-safe Builder pattern using Kotlin. This pattern allows developers to create declarative and concise DSLs. Our implementation will be a Burger Builder that enables our users to create Burger objects expressively. ## Goals ## At the end of the … |
The End.