-
Notifications
You must be signed in to change notification settings - Fork 50
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
value didn't update in NavHost #271
Comments
Can you try 1.6.0-beta02 and check if it's working for you? |
oh, thanks! It does work |
I'm having a similar issue on |
When i tried the "1.6.0-beta02", i found that it resolved this issue on its own. |
Thinking more about it, I think this might be the desired behaviour or else deeplinks might break. All the parameteres should come from the deeplink url. But not 100% sure yet |
I have a very similar issue in 1.6.0-rc05. Here is example: var screenType = ScreenType.MEDIUM |
If you find that the screen always displays the previous value which is outdated, maybe these will help: In current version, updating the value outside of a NavHost could not trigger the recomposition( I guess) , namely passing values directly into a NavHost is not recommended. It seems like you want to observe to the window size, perhaps setting up a kotlin object and check it in somewhere or simply delaying the update to NavHost scope, will be better. |
Thank you for suggestion! I moved to Navigation from JetBrains. It still in Alfa but it does not have this problem and my project is not commercial yet. |
In 1.5.10, based on the sample app called Reply, I gave it a try. However, I found that the screenType in the scene retains its initial value while the one outside the NavHost is changed correctly.
Should I not have done this?
The text was updated successfully, but these errors were encountered: