1 year ago

#77226

test-img

Salil

Why does the UI flicker when using navigation component(xml) with Fragment and ComposeView?

I am using Jetpack Compose in an existing app with a XML based navigation graph.

The transition from FragmentA to FragmentWithComposeView ( and vice-versa) is not smooth and causes the UI to flicker. The UI is janky even with a single Text component. The transition uses a global action with below for the enter,exit, popEnter and popExit parameters.

@anim/nav_default_enter_anim.xml
@anim/nav_default_exit_anim.xml

Using below library versions:

activity compose - 1.4.0
compose material - 1.0.5
compose tooling - 1.0.5
material compose theme adapter - 1.1.3

Is there a solution or is XML based UI better in this case?

android

android-jetpack-compose

android-jetpack-navigation

0 Answers

Your Answer

Accepted video resources