suika
10/22/2025, 4:39 AMsetContent {
var active by remember { mutableStateOf(true) }
Box {
ReusableContentHost(active) {
val innerData = remember { mutableStateOf("Za") }
}
}
val outerData = remember { mutableStateOf("Zb") }
val composition = currentComposer.composition
LaunchedEffect(active) {
// !!! When active changes from true to false, the Za stored in the slottable still remains and has not been cleaned up.
// Group(25) key=207, nodes=0, size=2 aux=false, slots=[86: false]
// Group(26) key=-1685893985, nodes=0, size=1, slots=[87: σ(value=Za]
composition.printSlotTable()
}
Box(
Modifier
.fillMaxSize()
.clickable {
active = !active
Log.e("clickable", "$active")
}) { }
}suika
10/24/2025, 9:10 AMactive is false, the content is deactivated and all remembered state is treated as if the content was deleted. Could it be that my understanding is wrong, or that my example doesn’t match the function's functionality?