Hi! I read in the documentation for rememberSaveable that one should be careful with the amount of data read/written since it could slow down the UI performances. It also said one should consider viewmodels instead. But as far as I know, SaveStateHandle also uses a read/write solution. Are there any significant differences between the two mechanisms or is it because viewmodels do the reading/writing in a different coroutine/thread?
j
Jonathan
06/12/2025, 1:26 PM
I thing the issue with
rememberSavable
is that it’s a Composable so maybe it could affect
Composition
time? IE slow down your UI.
j
juliocbcotta
06/17/2025, 3:14 PM
both save stuff in a Bundle in the main thread, the biggest limitation is the Bundle size (around 1MB, I think), so don't save huge lists (lists of products for instance would be no no) there.