How can I achieve the same state preservation in this library as I had with a stack of activities? When I open a new activity on top of another, the state of the underlying activity is preserved, including all Views and ViewModels. However, when trying to replicate this behavior with AnimatedHost in Jetpack Compose, the state of the previous screen is lost. This includes the state managed by remember, AndroidView, and ViewModel. What can I do to ensure that the state of the previous screen is retained when navigating between screens using AnimatedHost?
How can I achieve the same state preservation in this library as I had with a stack of activities? When I open a new activity on top of another, the state of the underlying activity is preserved, including all Views and ViewModels. However, when trying to replicate this behavior with AnimatedHost in Jetpack Compose, the state of the previous screen is lost. This includes the state managed by remember, AndroidView, and ViewModel. What can I do to ensure that the state of the previous screen is retained when navigating between screens using AnimatedHost?