MoIbrahim15/Android-Kotlin-MVI-CleanArchitecture
37.7
Weak · 22 September 2026
5.6k
lines of production code
Kotlin
primary language
7
measurements over time
What this system is
This is an Android application built with Kotlin, utilizing a modular Clean Architecture and the MVI (Model-View-Intent) pattern for state management. It provides user authentication, account management, and blog creation and browsing capabilities, supported by a layered codebase that separates remote API integration, local caching, and domain logic. The system manages user sessions, handles UI state transitions, and persists data locally using Room and SharedPreferences.
Features
Added Koin dependency injection modules and utility constants
Introduced new Koin modules for dependency injection: AuthModule registers the AuthViewModel, while MainModule registers the SessionManager, various mappers (Token, User, BlogPost), and ViewModels for the main, account, blog, and create-blog features. Additionally, a new Constants class was added to the utils package, defining UI request codes and a helper method to detect pagination completion based on error responses.
features/src/main/java/com/mi/mvi/koin, features/src/main/java/com/mi/mvi/utils · medium confidence
Added account management features including view, update, and password change
The account feature now includes a main account view, an update account screen, and a change password screen. Users can view their profile details, edit their email and username, and change their password through the new fragments and viewmodel.
features/src/main/java/com/mi/mvi/features/main/account · high confidence
Added common navigation, session, and UI helper components
The app introduces several new common utilities to support the MVI architecture and navigation. A new BottomNavController class manages the bottom navigation bar, handling fragment transactions, back stack navigation, and reselection events. A SessionManager class is added to manage user authentication tokens and handle login/logout states using LiveData. Additionally, UI helper extensions are provided for displaying Toast messages and MaterialDialogs for success, error, and confirmation scenarios, along with interfaces for data state and UI communication listeners.
features/src/main/java/com/mi/mvi/common · high confidence
Blog feature implemented with modularized UI and MVI architecture
The blog feature is now implemented as a modularized feature, introducing a complete MVI (Model-View-Intent) architecture for managing blog states. This includes new fragments for creating, viewing, and updating blog posts, alongside a dedicated ViewModel and state classes to handle business logic. The UI utilizes the Kiel library for RecyclerView adapters and integrates with Koin for dependency injection, providing a structured approach to handling blog data, image uploads, and user interactions.
features/src/main/java/com/mi/mvi/features/main/blog · high confidence
Centralized build configuration and dependency management for Android modules
The buildSrc module now provides a centralized, Kotlin-based Gradle plugin that automatically configures Android build settings (compileSdk 30, minSdk 21, Java 1.8), applies standard plugins, and injects a comprehensive set of shared dependencies (Koin, Retrofit, Room, Coroutines, etc.) into feature modules. This change introduces a modular architecture where common dependencies and build configurations are defined in a single source of truth, simplifying updates and ensuring consistency across the application's features, cache, remote, data, and domain modules.
buildSrc · high confidence
Introduce base MVI components for Android activities, fragments, and ViewModels
Added new base classes for the MVI architecture: BaseActivity, BaseFragment, and BaseViewModel. These provide shared functionality for handling UI communication, state changes, and event processing across the application. The base classes implement interfaces for data state changes and UI communication, enabling consistent behavior for all activities, fragments, and view models in the features module.
features/src/main/java/com/mi/mvi/base · high confidence
Introduce domain layer for account, authentication, and blog management
Added the domain layer to support account, authentication, and blog features. This includes data state wrappers (DataState, StateResource), view state models (AuthViewState, AccountViewState, BlogViewState, CreateBlogViewState), repository interfaces (AuthRepository, AccountRepository, BlogRepository, CreateBlogRepository), and use cases for login, registration, password changes, and blog CRUD operations.
domain · high confidence
Introduce local caching layer for users, tokens, and blog posts
The cache module now provides a complete local persistence layer using Room and SharedPreferences. It includes database entities and DAOs for accounts, auth tokens, and blog posts, along with Koin modules that wire up the database, entity mappers, and data source implementations. This enables the app to store and retrieve user profiles, authentication tokens, and blog post content locally, supporting offline access and faster subsequent loads.
cache · high confidence
Introduce modularized auth feature with login, register, and password reset flows
Users can now log in, register a new account, or reset their password through a dedicated auth module. The app launches a splash screen that checks for an existing session and routes users to the main dashboard if authenticated, otherwise to the login screen. The login and register screens share a common ViewModel that handles authentication events, while the password reset flow uses a WebView to a remote URL and communicates results back to the UI.
features/src/main/java/com/mi/mvi/features/auth · medium confidence
Introduced event state models for account, auth, blog, and create blog features
Added new sealed classes defining the event states for account management, authentication, blog browsing, and blog creation. These include specific event types such as login, register, and token check for auth; account updates and password changes for account management; and search, update, and delete operations for blogs. This structure supports the MVI architecture by explicitly modeling user interactions and state transitions for these core features.
features/src/main/java/com/mi/mvi/events · medium confidence
Introduces a new MVI-based data mapping layer for the blog feature
The application now includes a new data mapping layer in the \features/src/main/java/com/mi/mvi/mapper\ directory, implementing the MVI (Model-View-Intent) pattern. This change introduces a \Mapper\ interface and specific implementations (\BaseMapper\, \BlogPostMapper\, \TokenMapper\, \UserMapper\) that handle the conversion between domain models (e.g., \BlogPost\, \User\) and their corresponding view models (e.g., \BlogPostView\, \UserView\). This allows the UI layer to interact with a clean, immutable domain model while the mapper handles the translation to and from the view state, supporting the ongoing modularization of the blog feature.
features/src/main/java/com/mi/mvi/mapper · high confidence
Introduces data layer for blog, auth, and account management
The data module now provides the complete data access layer for the application, introducing repository implementations for authentication, account management, and blog operations. This includes remote data sources for API calls, cache data sources for local storage, and mappers to convert between domain models and data entities. The \NetworkBoundResource\ helper class is added to manage the flow of data between network and cache, handling loading states, errors, and cache updates. Specific implementations like \AuthRepositoryImpl\, \AccountRepositoryImpl\, \BlogRepositoryImpl\, and \CreateBlogRepositoryImpl\ are introduced, each handling their respective domain logic and state management.
data · high confidence
Project initialization with documentation and licensing
The repository was initialized with essential project files, including an MIT License file and a README.md that outlines the Android Kotlin MVI Clean Architecture app's features, such as modularization, Koin for dependency injection, and Coroutines. Additionally, the local.properties file was updated to reflect the correct SDK directory path.
(repo-wide) · high confidence
Remote data layer and API integration for blog and auth features
The remote module now includes the full implementation for remote data sources and API services for blog and authentication. This adds the necessary network calls, data models, and mappers to support blog post operations (create, update, delete, search) and user authentication (login, register, account management).
remote · high confidence
Behavioural changes
App initialization and UI assets restructured
The application now initializes via a new \BaseApp\ class that sets up Koin dependency injection, replacing the previous startup logic. The \AuthActivity\ has been removed and replaced with a \SplashActivity\ as the launcher entry point. Additionally, numerous legacy resources have been removed, including animation XMLs, drawable icons, menu definitions, and color/style definitions, as the app transitions to a new architecture.
app/src · high confidence
Updated Gradle wrapper to version 6.8.2
The Gradle wrapper has been upgraded from version 6.1-rc-1 to 6.8.2. This change updates the build tooling used to compile and run the project, ensuring compatibility with newer Gradle features and improvements.
gradle · high confidence
Dependencies
Migrate to Kotlin DSL and modularize project structure
The project build files have been migrated from Groovy to Kotlin DSL (build.gradle.kts), introducing a modular architecture with separate Gradle scripts for app, cache, data, domain, features, and remote modules. The top-level build configuration now includes ktlint and detekt plugins for code style and static analysis. Additionally, Gradle performance settings in gradle.properties have been updated to enable parallel execution, daemon, and caching.
(dependencies) · high confidence
Written by watchdog.canine.dev from the codebase's own history, inside the signed delivery this page is composed from.
How this codebase got here
Score
- CAI 38 → 38 (-0.1)
- Rubric changed (rubric-2026.08.19 → rubric-2026.09.15) — scores are not directly comparable.
Lenses
- Code Health 100 → 99 (-0.1)
- Architecture 100 → 92 (-7.7)
- Maturity 47 → 47 (+0.0)
- Readiness 15 → 15 (+0.0)
- Security 100 → 100 (+0.0)
- Domain Modelling 38 → 40 (+2.0)
Resolved (6)
- Dependency hygiene not measured — dependency manifest found but not parsed for hygiene
- Duplicated block (10 lines × 2) (data/src/main/java/com/mi/mvi/data/entity/BlogPostEntity.kt)
- Duplicated block (10 lines × 2) (features/src/main/java/com/mi/mvi/features/main/blog/UpdateBlogFragment.kt)
- Duplicated block (19 lines × 2) (data/src/main/java/com/mi/mvi/data/repository/AuthRepositoryImpl.kt)
- No exposed public API
- dormant codebase — no living knowledge left to concentrate
New (10)
- Change coupling: MainActivity.kt ↔ BlogFragment.kt (features/src/main/java/com/mi/mvi/features/main/MainActivity.kt)
- Dependency hygiene PARTLY measured — Maven/Gradle declarations read, no dependency graph resolved
- Documentation: no installation or build instructions (README.md)
- Documentation: no usage examples (README.md)
- Duplicated block (10 lines × 2) (features/src/main/java/com/mi/mvi/features/main/blog/UpdateBlogFragment.kt)
- Duplicated block (11 lines × 2) (data/src/main/java/com/mi/mvi/data/entity/BlogPostEntity.kt)
- Duplicated block (11 lines × 2) (data/src/main/java/com/mi/mvi/data/mapper/BlogPostMapper.kt)
- Duplicated block (13 lines × 2) (data/src/main/java/com/mi/mvi/data/mapper/BlogPostMapper.kt)
- Duplicated block (35–37 lines × 2) (data/src/main/java/com/mi/mvi/data/repository/AuthRepositoryImpl.kt)
- Duplicated block (7 lines × 2) (features/src/main/java/com/mi/mvi/features/main/blog/UpdateBlogFragment.kt)
Written by watchdog.canine.dev from the codebase's own history, inside the signed delivery this page is composed from.
Survey your own repository
MoIbrahim15/Android-Kotlin-MVI-CleanArchitecture was measured the same way every project in this corpus was: the same rubric, at a pinned commit, with the result published in full. Point a surveyor at a repository you know and see whether you agree with it.
About this page
- The score is its most recent published measurement, taken on 22 September 2026 at a pinned commit. It is not a live figure and does not change until the project is measured again.
- Measured at commit 4a6dca75cb77bc6b78db9191acd6ae5a7ad0be55 — the exact code this score is about.
- Scored under rubric-2026.09.15 — the same rubric and the same method as every other entry in this index.
- Measured by watchdog.canine.dev using codehealth-analyzer preprod-90d5d2fe38ee.