Category "android-jetpack"

Composable not recomposing when ViewModel updated from a different Composable

I am developing an Android app using Jetpack Compose. The app shows a list of items. It also has a top bar containing a search bar. We have 3 composable: the li

android:autoSizeTextType in Jetpack Compose

Is there a way to adjust the text to always resize depending a fixed height ? I have a column that has a fixed height and in which the text inside should always

Compose preview doesn't work at all - project needs to be compiled

I use Android Studio Bumblebee 2021.1.1 Patch 3 built on March 16, 2022 androidx.compose.ui:ui-tooling, androidx.compose.ui:ui-tooling-preview, androidx.compose

How can I get string resource in Jetpack composable test

We can get the string resource in Composable through stringResource like @Composable fun Heading( @StringRes textResource: Int ) { Text( text =

Cannot create instance of viewmodel after using Hilt in Android

Here is my AllFilesListViewModel class. class AllFilesListViewModel @ViewModelInject constructor( private val pdfItemRepository: PdfItemRepository):ViewMod

Cannot create instance of viewmodel after using Hilt in Android

Here is my AllFilesListViewModel class. class AllFilesListViewModel @ViewModelInject constructor( private val pdfItemRepository: PdfItemRepository):ViewMod

How to identify multiple instances of Glance App Widget

I am trying to create a widget which shows information about a hardware device. There can be multiple of these devices and user will be able to add same widget

Is it possible to use Paging (As part of android jetpack) without using Room DB?

Right now I'm working on an Android project which contains a RecyclerView with a large amount of data. For improving the app's performance I wish to implement

Navigation Component: IllegalStateException Fragment not associated with a fragment manager

I'm using the Navigation Component version 2.1.0-rc01 and I navigate back and forth between 3 screens using Navigation.findNavController(it).navigate(R.id.act

Resources$NotFoundException - Failed to open file '...fragment_list.xml': No such file or directory

I am learning MVVM and have run into an issue, and I am getting the following errors: Resources$NotFoundException: File res/layout/fragment_list.xml from xml ty

Jetpack compose : BottomSheet state change callback

How can i achieve callback/listener mechanism on JetPack Compose BottomSheet state changes? Something similar to: @Override public void onStateChanged(@