This is a Kotlin Multiplatform Project for a news application that supports Android, iOS, Web, and Desktop platforms.
-
Kotlin Multiplatform: The project is built using Kotlin Multiplatform, allowing code sharing across different platforms.
-
Android: The Android app is built using Kotlin and leverages the Android SDK.
-
iOS: The iOS app is built using Kotlin Multiplatform, enabling code reuse with the iOS platform.
-
Web & Desktop: The project includes support for both Web and Desktop platforms, providing a versatile user experience.
-
Koin: Dependency injection framework for managing dependencies in a Kotlin Multiplatform project.
-
ComposeImageLoader: Image loading library for Jetpack Compose, used for loading and displaying images efficiently.
-
Ktor Client: A multiplatform HTTP client for making network requests in a Kotlin Multiplatform project.
-
Ski: A lightweight and fast image loading library for Kotlin Multiplatform projects.
-
Moko MVVM: A multiplatform MVVM library that helps in implementing the Model-View-ViewModel architecture.
To build the project, follow these steps:
- Clone the repository:
git clone https://github.com/KhubaibKhan4/News-KMP.git
- Open the project in your preferred IDE.
- Build and run the project on your desired platform.
- check your system with KDoctor
- install JDK 17 on your machine
- add
local.properties
file to the project root and set a path to Android SDK there
To run the application on android device/emulator:
- open project in Android Studio and run imported android run configuration
To build the application bundle:
- run
./gradlew :composeApp:assembleDebug
- find
.apk
file incomposeApp/build/outputs/apk/debug/composeApp-debug.apk
Run the desktop application: ./gradlew :composeApp:run
To run the application on iPhone device/simulator:
- Open
iosApp/iosApp.xcproject
in Xcode and run standard configuration - Or use Kotlin Multiplatform Mobile plugin for Android Studio
Run the browser application: ./gradlew :composeApp:jsBrowserDevelopmentRun