Hello,
I've encountered an issue where I'm seeing janky frames and unsmooth transitions when navigating from Screen A to Screen B with a 300ms horizontal slide LinearEasing animation. This issue becomes more pronounced when:
1. I add a Crossfade for the state change.
2. The screen complexity increases.
3. Navigation buttons have a ripple effect.
Here's a link to a sample project and some videos I've created to demonstrate the issue: [Sample Project](
https://issuetracker.google.com/issues/301488789). However, as this is a P4 issue, I'm not expecting a quick response. Also, please note that the lag isn't as visible in this sample project due to its simplicity, but it's still present.
In more complex screens, I've even noticed this issue on my Samsung S22. Here are some technical details about my project:
- I run the project with R8, in release mode.
- I'm using Material3.
- All the libraries I'm using are up to date.
- I've checked the layout inspector and there are no recompositions during the animation.
- I'm using stable annotated classes and ImmutableList for lists.
- For navigation, I'm using Voyager, but I've also checked with Appyx, fragment navigation, and Slack Circuit, and the issue persists.
- I'm using Koin for DI, but the issue persists even in the sample project where I'm not using any DI.
- I'm using the Orbit MVI library for MVI architecture, but the issue persists even in the sample project where I'm not using it.
- I've moved all unnecessary calculations out of composables.
Interestingly, I've noticed occasional janky frames on simpler screens on slower devices like the Xiaomi POCO x3 or Samsung A20S. However, when I run the Maxi Zoo application from the store, which is fully built in Compose, I don't see any janky frames, even with more complex screens and a ripple effect. This leads me to believe that I might need to add something to my Gradle file or elsewhere, but I can't figure out what it is. Any help would be greatly appreciated.