Experimenting with using SnapshotState APIs in Android View-only rendering world (just including the compose runtime artifact).
Using
snapshotFlow
to observe `mutableStateOf<T>`s in `Fragment`s. Noticing that
withMutableSnapshot
is required when updating the state (from Android View callbacks for example) in order to propagate updates, but I don’t understand why it’s required in this case… 🤔
a
Arsen
11/29/2021, 11:23 PM
iirc Snapshot system should be notified in order to apply pending changes, which ui part of compose periodically does. Checkout Snapshot.sendApplyNotifications() method