Advitiay Anand
05/09/2023, 2:33 PMViewModel
's constructor (as it is constructed using hiltViewModel()
).
I read a bit and found that NavArguments and SavedStateHandle should be used to pass arguments in ViewModel, ideally.
Yet, that only seems to support very limited NavArg.Type
's as well. I don't get what I am doing wrong.
Are we not supposed to pass navigation lambdas to ViewModel? Because the state that needs to trigger navigation resides inside the ViewModel only.
Please give your helpful inputs :)
Thread in Slack ConversationStanislav Georgiev
05/23/2023, 7:15 AMAdvitiay Anand
05/23/2023, 7:21 AM