I am confused by all the compose and multiplatform stuff. I want to build a client SDK that exposes view models to my clients, which are an iOS app, android app and a react js web app.
Can I use compose-viewmodels for this? I plan to manage my dependencies with koin. I want to integrate the view models into react by subscribing to the state-flows and publishing them into react "useState" hooks.
f
François
04/15/2025, 11:04 AM
Can I use compose-viewmodels for this?
Yes you van (at least for iOS)
look at that example.
Instead of exporting the Android ViewModel, export the CMP viewmodel
a
audax
04/15/2025, 11:30 AM
Nice, that looks promising!
Theoretically it should also work with a JS target, without building the app itself with compose and your repository should give me enough hints to build all the boilerplate! 🙂