This is an Android application built with Kotlin Multiplatform and Compose Multiplatform that allows users to view, search, sort, and filter a list of users. It also supports adding new users and works offline.
- View User List: Paginated list of users with smooth scrolling.
- Search: Search for specific users by name.
- Sort: Sort users by name.
- Filter: Filter users by city.
- Add User: Add new users to the list.
- Offline Support: Local persistence using Room Database.
- Pagination: Efficient loading of data using Paging 3 and RemoteMediator.
- UI: Compose Multiplatform (Jetpack Compose).
- Architecture: Clean Architecture with MVVM.
- Dependency Injection: Hilt (Android side).
- Networking: Ktor Client.
- Local Persistence: Room Database (KMP).
- Pagination: Paging 3.
- Image Loading: Coil 3.
- Concurrency: Kotlin Coroutines & Flow.
- Serialization: Kotlinx Serialization.
- Clean Architecture: Separation of concerns into Domain, Data, and UI layers ensures the app is maintainable and testable.
- MVVM: State management using ViewModels and Flows provides a reactive UI.
- Room + RemoteMediator: This combination ensures a "Single Source of Truth" strategy, where the UI always observes the local database, and the RemoteMediator handles syncing with the network. This provides seamless offline support and smooth pagination.
- Material 3: The UI follows Material Design 3 guidelines for a modern and accessible look.
- Adaptive Layout: Designed to work well on different screen sizes.
- Build and Run: Use Android Studio to run the
composeAppon an Android device or emulator. - Search: Use the search bar at the top to find users by name.
- Sort/Filter: Tap the filter icon to change sorting or filter by city.
- Add User: Tap the Floating Action Button (+) to add a new user.
- Offline: Disable your internet connection; the app will still show previously loaded users from the local database.
The application uses a RESTful API for CRUD operations. (Note: Replace the placeholder BASE_URL in UserApiService.kt with the actual Accurate API endpoint).
- Android:
./gradlew :composeApp:assembleDebug - iOS: Open
iosAppin Xcode (still ondevelopment).