Skip to content

Drjacky/MVVMTemplate

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Β 

History

389 Commits
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 

MVVMTemplate πŸ§žβ€

Language AGP License Actions Status Build Status Quality Gate Status FOSSA Status Android Arsenal CodeScene Code Health

A simple Android template that lets you create an Android project quickly.

How to use πŸ‘£

Just click on Use this template button to create a new repo starting from this template.

Architecture πŸ—

This project follows Clean Architecture with MVVM and is organized into a multi-module structure:

MVVMTemplate/
β”œβ”€β”€ app/                     # Application module (MainActivity, Navigation, DI wiring)
β”œβ”€β”€ build-logic/             # Convention plugins (shared build configuration)
β”œβ”€β”€ core/
β”‚   β”œβ”€β”€ common/              # Shared base classes, utilities, DataStore
β”‚   β”œβ”€β”€ data/                # Repository implementations, data sources, API models
β”‚   β”œβ”€β”€ domain/              # Use cases, domain models, repository interfaces
β”‚   β”œβ”€β”€ network/             # Retrofit setup, OkHttp configuration, network response handling
β”‚   β”œβ”€β”€ testing/             # Shared test utilities (TestDispatcherRule, fakes, test data)
β”‚   └── ui/                  # Shared Compose UI components, theming, screen states
└── feature/
    └── products/            # Products feature (list, detail, choose screens)

The app demonstrates both RxJava and Coroutines side by side - users choose which reactive approach to explore at runtime via a choose screen.

Features πŸ•Ή

Core

Reactive & Concurrency

Dependency Injection

Networking & Serialization

Navigation

  • Navigation 3 - Type-safe Compose navigation with NavKey and NavDisplay

UI & Theming

  • Material 3 with dynamic color, light/dark theme, edge-to-edge support
  • Lottie - Vector animations
  • Coil - Image loading
  • Palette - Dynamic card coloring from image palettes
  • Paging 3 - Pagination (both Coroutine and RxJava data sources)
  • Compose stability configuration (compose_compiler_config.conf) and compiler metrics/reports

Data

Quality & Tooling

Testing

  • Unit tests with Fakes over Mocks pattern
  • Truth - Fluent assertions
  • Turbine - Flow testing
  • Coroutines Test - TestDispatcherRule for deterministic coroutine testing
  • Shared core:testing module with reusable fakes and test data

Accessibility & Internationalization

  • Semantic properties for TalkBack (mergeDescendants, heading, contentDescription)
  • Touch target sizing (48dp minimum)
  • String resources with translator context comments
  • Non-transitive R classes for proper resource scoping

CI 🏭

This template uses GitHub Actions as CI.

Available workflows:

Tasks πŸ”§

  • dependencyUpdates - Displays the dependency updates for the project
  • detekt - Runs static Kotlin code analysis for the whole project
  • buildHealth - Provides advice for managing dependencies and applied plugins
  • ossIndexAudit - Scans dependencies using Sonatype OSS Index for known vulnerabilities

References 🧷

Contributing 🀝

Feel free to open an issue or submit a pull request for any bugs/improvements.

Result πŸ“Ί

License βš–οΈ

FOSSA Status

Sponsor this project

 

Contributors

Languages