Skip to main content

All Questions

Filter by
Sorted by
Tagged with
1 vote
1 answer
109 views

Compose Navigation - Incompatibility and workaround with Serialized Objects

I have a project where I am using the material 3 top app bar. Naturally when I am on my home page, I want to hide the back button since there is nothing on the backstack. However, I am not using ...
Kenny Sexton's user avatar
1 vote
0 answers
85 views

Jetpack compose typesafe navigation crash

Restoring the Navigation back stack failed: destination 30355061 cannot be found from the current destination mj0(0x0) startDestination={oj0(0x2e873c) route=x.x.x.x.composeNavigation.MenuScreen} I ...
Rob's user avatar
  • 61
0 votes
1 answer
443 views

Compose Multiplatform Navigation: handle Back button with Navigator BackStack

I am working on an application, which has a complex nav graph. The problem is How to handle back button in topAppBar in this situation? I want to use navController to know it's navigated from MainNav ...
Shahriyar Aghajani's user avatar
2 votes
1 answer
506 views

Issue with popBackStack and Type Safety in Navigation Compose wit Serialization

I'm working on an Android app using Navigation Compose with type safety. I have the following navigation setup with four screens: ScreenA, ScreenB, ScreenC, and ScreenD. The navigation flow is as ...
Androidew1267's user avatar
0 votes
0 answers
28 views

How to set up NavHost for android UI testing?

java.lang.IllegalArgumentException: Cannot navigate to NavDeepLinkRequest{ uri=android-app://androidx.navigation/movies/ }. Navigation graph has not been set for NavController androidx.navigation....
RocketMan's user avatar
2 votes
1 answer
1k views

On Android, new version of Navigation Compose (2.8.0-alpha08 and up) not compatible with TextFieldState?

I am building an Android app based on a online course from PL-Coding, I wanted to implement the new compose navigation version (2.8.0-alpha08) with type safe navigation arguments. The problem is that ...
Damon's user avatar
  • 129
0 votes
1 answer
85 views

Is Incremental Migration to Jetpack Compose Navigation Possible with Mixed Traditional Fragment Navigation?

I am currently working on migrating our application from using traditional fragment-based navigation to Jetpack Compose Navigation. All our screens are currently built with fragments that utilize ...
Natasa Ilievska's user avatar
0 votes
1 answer
100 views

java.lang.IllegalArgumentException: CreationExtras must have a value by `SAVED_STATE_REGISTRY_OWNER_KEY`

sToday I've upgraded some libraries then I started the app and when I click the button that is navigation button , I got this error : java.lang.IllegalArgumentException: CreationExtras must have a ...
gkhn.akbs's user avatar
0 votes
0 answers
60 views

Navigation destination is being called 4 times for some reason in jetpack compose?

This is my NavGraph, here the destination "VerificationScreen/{verificationId}" is being called 4 times thus creating the viewmodel 4 times. What could be reason for this? @Composable fun ...
skinnyhrit's user avatar
0 votes
0 answers
500 views

Navigation Compose Error : " cannot be found in the navigation graph ComposeNavGraph(0x0) "

I'm passing object of Student to StudentPage with Gson this is NavGraph file composable( Screen.StudentPage.route, arguments = listOf( navArgument("studentObject") { ...
gkhn.akbs's user avatar
1 vote
0 answers
86 views

Jetpack Compose Deeplinks Redirecting Incorrectly Despite Different uriPattern

I'm encountering an issue with Jetpack Compose deeplinks where they're consistently redirecting to the ResetPasswordRoute destination, despite having different uriPattern configurations. Here's an ...
Ezzy Wachira's user avatar
1 vote
0 answers
490 views

Given component holder class androidx.activity.ComponentActivity does not implement interface dagger.hilt.internal.GeneratedComponent

I'm doing an app in Android/Kotlin as a portfolio, and I want to use navigation testing to do UI tests. But the app also has Hilt and I had to configure both to run the tests, using Hilt android ...
MuriTG25's user avatar
1 vote
2 answers
683 views

Navigation compose deprecated backQueue

I updated the androidx.navigation:navigation-compose from version 2.5.3 to 2.7.4 and I get the error:Cannot access 'backQueue': it is private in 'NavController' private fun NavOptionsBuilder....
Zsolt's user avatar
  • 3,760
4 votes
1 answer
2k views

do I have to pass the navController to all my composables?

I am new to jetpack Composable. I'm trying to build a new app using Composables in MainActivity. so there will be only one activity and no fragments and all Composables. I want to know do I have to ...
郑迎风's user avatar
  • 119
1 vote
1 answer
166 views

How to use navigation in Jetpack Compose android

While trying to navigate from MapsScreen to SignupScreen in Jetpack Compose, although I see in logcat that SignUp is clicked,I am not able to navigate to SignupScreen. I have setup the navgraph and ...
Kaleab Woldemariam's user avatar
1 vote
0 answers
94 views

Injecting NavBackStackEntry to composable in tests of NavHost

I'd like to pass mandatory nav args into my (Robolectric) tests so that I can run the code for my lower level composable. My code is based on how navigation was used in an earlier version of the TiVi ...
Alix's user avatar
  • 2,827
1 vote
1 answer
676 views

Clear Bottom Nav Saved State - Jetpack Compose

The current flow of my app is as follows: Login Screen -> Home Screen with 4 bottom nav tabs. I'm saving the state of my bottom nav tabs using android documentation as stated here: https://...
androiddev321's user avatar
0 votes
2 answers
1k views

Compose Navigation screen blinks when navigate to another screen

When i am trying to navigate to another screen by .clickable on modifier i got this. Never faced such problem earlier. This is how i navigate and what i see on screen. What i show if response from ...
euopaxc's user avatar
  • 23
0 votes
0 answers
30 views

Naviagtion XYZ cant be found from current destination()

I often get this error a lot in all my projects Navigation action/destination com.speakerbooster.volumebass.equalizersound.amplifier:id/action_premiumFragment_to_dashboardFragment cannot be found from ...
Muhammad Awais's user avatar
3 votes
1 answer
1k views

How to prevent entire composable from recomposing when popping backstack in navigation composable

What currently is happening: I have a grid screen and on clicking on the list I navigate to the detail screen Now on clicking the back button I navigate back to the list screen What is the issue: ...
Devrath's user avatar
  • 42.8k
4 votes
0 answers
993 views

Jetpack Compose Navigation Deep Link causes duplicate activity

I'm trying to show a notification that when clicked will open ChatScreen. It does open ChatScreen but started as a different activity, so there's 2 MainActivity in the back stack. I use Compose ...
Risal Fajar Amiyardi's user avatar
2 votes
1 answer
2k views

How to handle state flow on back navigate on compose

I am following unidirectional flow in compose for ui state so basically i have sealed class as follow sealed class UiState{ objet Loading:UiState() object Success:UiState() object Error(val error:...
Kartik's user avatar
  • 21
3 votes
1 answer
1k views

Compose navigation lose state after pop screen (navigate for network success)

I am using compose navigation with single activity and no fragments. class MainActivity : ComponentActivity() { override fun onCreate(savedInstanceState: Bundle?) { super.onCreate(...
jiechic's user avatar
  • 91
7 votes
1 answer
2k views

Jetpack Compose Navigation - Passing local file location as string

I am trying to pass audio file location(/storage/emulated/0/Android/media/...) as string from first screenhome_screen to second screendetail_screen, When I pass normally above string as a parameter I ...
iamkdblue's user avatar
  • 3,614
4 votes
1 answer
3k views

How to integrate AlertDialog with Navigation component in Jetpack Compose?

I am using Jetpack Compose and the Android navigation component. When I am on a screen with an AlertDialog, I am unable to navigate back. I guess it's due to the AlertDialog catching the back button ...
me.at.coding's user avatar
  • 17.4k
1 vote
1 answer
8k views

Does NavOptionsBuilder.launchSingleTop work with nested navigation graphs in Jetpack Compose?

I'm using BottomNavigation in Jetpack Compose with navigation-compose:2.5.0-alpha04 and I want to encapsulate each tab's flow with nested navigation. To achieve this I created a single NavHost with ...
Calamity's user avatar
  • 980
1 vote
2 answers
1k views

Add menu icons from fragement into host actvity toolbar - Navigation component

Iam using single activity navigation component structure. In host activity iam using navigation drawer and bottom navigation. So There are 2 frgaments inside bottom navigation Fragment A and Fragment ...
Navin Kumar's user avatar
  • 3,977
9 votes
4 answers
3k views

Screens are flashing when I navigate to them in Dark theme using Navigation-compose

I am using Navigation-Compose in my app : override fun onCreate(savedInstanceState: Bundle?) { super.onCreate(savedInstanceState) setContent { ComposeTheme { ...
Ali's user avatar
  • 9,994
3 votes
0 answers
2k views

Navigation in Jetpack Compose - Fragments/ViewModels

So I'm checking this official Compose tutorial https://developer.android.com/courses/pathways/compose There is Jetpack Compose Navigation https://developer.android.com/codelabs/jetpack-compose-...
user924's user avatar
  • 11.9k
12 votes
1 answer
3k views

How to do Assisted Injection with Navigation Compose?

I've a composable called ParentScreen and a ViewModel named ParentViewModel. Inside the ParentViewModel, I am collecting a value from my repo. class MyRepo @Inject constructor() { fun ...
theapache64's user avatar
  • 11.7k