This projects provides a robust and scalable foundation for building an Android applications. Leveraging the power of Jetpack Compose for UI development, it implements the MVVM (Model-View-ViewModel) architecture for clean and maintainable code.
This documentation provides an overview for an Android project structured using the MVVM (Model-View-ViewModel) architecture. THe project uses Koin for dependency injection, Retrofit for defining RESTful API interfaces, and OkHttp for handling network request. Additionally, it includes custom Composable functions for reusable and modular UI development.
Technology Stack
Kotlin: 1.9.0 The primary programming language for Android development, offering concise syntax, null safety, and functional programming features.
Android SDK: API 34 The latest Android development kit providing access to the full range of Android device features and capabilities.
Jetpack Compose: BOM 2023.08.00 A modern toolkit for building native Android UI. Using the Compose BOM (Bill of Materials) ensures consistent versions across all Compose libraries, simplifying dependency management and updates.
Architecture: MVVM (Model-View-ViewModel) Promotes a clear separation of concerns, allowing independent development, testing, and maintenance of the UI and business logic.
Networking: Retrofit + OkHttp
Retroft: Used for defining REST API with type-safe HTTP client generation.
OkHttp: Handles HTTP request with advanced features like interceptors, global configuration, and cancellation.
Dependency Injection: Koin A pragmatic and lightweight dependency injection framework for Kotlin, making it easier to manage and test dependencies.
State Management: ViewModel + Stateflow Utilizes Android Architecture Components ViewModel in conjunction with Kotlin Flow for managing and observing UI state, offering a reactive approach to state management.
Local Storage: Shared Preferences A lightweight key-value storage system for saving simple data. Ideal for storing small amounts of primitive data in key-value pairs, such as user preferences or app settings.
Image Loading: Coil A fast and efficient image loading library for Android backed by Kotlin Coroutines.
Asynchronous Programming: Coroutines Kotlin’s solution for asynchronous and non-blocking programming, simplifying background operations and thread management.