disposables
and RxScreenModel
you should first import cafe.adriel.voyager:voyager-rxjava
(see Setup).ScreenModel
provides a disposables
property. It's cleared automatically when the ScreenModel
is disposed.ScreenModel
needs to provide a state, use the RxScreenModel
. Use mutableState
to change the current state.state.subscribeAsState()
and handle the current state.