Kotlin Multi-Platform (KMP) Compose Example Projects. Focused on all platforms (Android/iOS/Desktop/Web/Server)
Install kdoctor : brew install kdoctor Run kdoctor : kdoctor
[If everything okay it will show check mark for each necessary items, if not okay install/fix it first]
Android: Run from android studio run button.
iOS: Run from android studio run button and if error shows, set execution target simulator device from run/debug configuration.
Desktop (Use terminal): ./gradlew :composeApp:run
Web (Use terminal): ./gradlew wasmJsBrowserRun
Server: Project -> server -> src -> pkg name -> Application.kt -> run main function.
1. Hello KMP Compose (Android/iOS/Desktop/Web): https://github.com/TouhidApps/KMP-Compose-Examples/tree/main/001_Hello%20KMP%20Compose
Basic KMP project with all platforms -> Documented to run in all platforms
2. WebView - KMP Compose (Android/iOS): https://github.com/TouhidApps/KMP-Compose-Examples/tree/main/WebView%20-%20KMP%20Compose
WebView KMP project for Android & iOS.
Features: Load from web, Load from local/offline html, Progress bar, Back/forward, Interceptor (To track url request)
3. BMI Calculator - MOKO MVVM (Android/iOS): https://github.com/TouhidApps/KMP-Compose-Examples/tree/main/KMP%20-%20BMI%20Calculator%20-%20MOKO%20MVVM
MOKO MVVM Library project for Android & iOS.
Features: MVVM implementation. BMI calculation.
4. Resource Sharing (Android/iOS/Web/Desktop): https://github.com/TouhidApps/KMP-Compose-Examples/tree/main/KMP%20Resource%20Sharing
Covered topics:
- Shared Image
- Shared String
- Localisation
5. Koin-Dependency-Injection-DI (Android/iOS/Web/Desktop): https://github.com/TouhidApps/KMP-Compose-Examples/tree/main/Koin-Dependency-Injection-DI
Covered topic:
- Koin for Dependency Injection (DI)
6. ViewModel KMP Compose (Android/iOS/Web/Desktop): https://github.com/TouhidApps/KMP-Compose-Examples/tree/main/ViewModel%20KMP%20Compose
Covered topic:
- ViewModel with Koin DI
7. KMP-Navigation (Android/iOS/Web/Desktop): https://github.com/TouhidApps/KMP-Compose-Examples/tree/main/KMP-Navigation
Covered topic:
- Navigation Drawer Menu
- Alert dialog
- Pager & Tab
- Compose Navigation
- Bottom Bar
- Bottom Sheet