$npx skillfedfor your agent

android-clean-architecture

Learn to organize Android and KMP projects using Clean Architecture principles, including module boundaries, dependency inversion, and layered data flow. Covers UseCase and Repository patterns, database integration with Room and SQLDelight, network clients with Ktor, and dependency injection setup with Koin or Hilt.

Android Clean Architecture provides patterns for structuring Android and KMP projects with layered modules and clean dependency rules.

AI-generated summary based on this skill's SKILL.md

234,207 35,692 MITupdated by affaan-m

Decision gist · record as of 2026-07-27

Android Clean Architecture provides patterns for structuring Android and KMP projects with layered modules and clean dependency rules. Learn to organize Android and KMP projects using Clean Architecture principles, including module boundaries, dependency inversion, and layered data flow. Covers UseCase and Repository patterns, database integration with Room and SQLDelight, network clients with Ktor, and dependency injection setup with Koin or Hilt.

manual: git clone https://github.com/affaan-m/ECC → cp -r ECC/skills/android-clean-architecture ~/.claude/skills/android-clean-architecture
skills/android-clean-architecture/SKILL.md · version 0fff59da

Use it when

  • android-clean-architecture recommends organizing modules by feature or layer.
  • android-clean-architecture implements UseCases as single-responsibility classes that orchestrate business logic by calling repositories.

Verify before relying

Read SKILL.md below before installing (1 file). Open directory: indexed for reading, not audited.

Same gist for agents: .md · .json

Install

affaan-m/ECC/android-clean-architecture · repository language: JavaScript

Open directory. Skills are indexed for reading, not audited. Review a skill's body before installing it.

Frequently asked questions

AI-generated answers based on this skill's SKILL.md and metadata

What are the main layers in android-clean-architecture?

android-clean-architecture organizes projects into three core layers: Domain (business logic and UseCases), Data (repositories, data sources, and database/network clients), and Presentation (UI, ViewModels, and state management). Each layer has clear responsibilities and communicates through well-defined interfaces, ensuring testability and maintainability.

How do you organize android modules in a clean architecture project?

android-clean-architecture recommends organizing modules by feature or layer. Feature modules contain domain, data, and presentation submodules; layer modules separate concerns vertically. Use gradle convention plugins to enforce dependency rules—presentation depends on domain, data depends on domain, and neither domain nor data depend upward. This prevents circular dependencies and maintains architectural integrity.

What is the usecase repository pattern android approach?

android-clean-architecture implements UseCases as single-responsibility classes that orchestrate business logic by calling repositories. Repositories abstract data sources (local/remote) behind a clean interface. UseCases are invoked from ViewModels or presenters, often using Kotlin Flow or coroutines. This pattern isolates business rules from framework details and makes testing straightforward.

How does android-clean-architecture handle dependency injection?

android-clean-architecture supports both Koin and Hilt for dependency injection. Koin uses module declarations to wire repositories, UseCases, and ViewModels; Hilt uses annotations like @HiltViewModel and @Inject. Both approaches decouple object creation from usage, enable easy testing with mock implementations, and centralize configuration for cleaner code.

How do you integrate Room and SQLDelight in clean architecture?

android-clean-architecture places database setup in the Data layer. Room and SQLDelight implementations are wrapped in repository classes that expose domain models, not database entities. Use mappers to convert between database and domain types. This keeps persistence details isolated and allows swapping database technologies without affecting business logic or UI layers.

What role does Ktor play in android-clean-architecture projects?

android-clean-architecture uses Ktor as a network client in the Data layer. Create a dedicated data source class that handles HTTP requests and response parsing. Repositories call this data source and map responses to domain models. Ktor's multiplatform support makes it ideal for KMP projects, keeping network logic testable and separate from domain and presentation concerns.

SKILL.md

Rendered from the published skill. Quoted content, verbatim.

Android Clean Architecture

Clean Architecture patterns for Android and KMP projects. Covers module boundaries, dependency inversion, UseCase/Repository patterns, and data layer design with Room, SQLDelight, and Ktor.

When to Activate

  • Structuring Android or KMP project modules
  • Implementing UseCases, Repositories, or DataSources
  • Designing data flow between layers (domain, data, presentation)
  • Setting up dependency injection with Koin or Hilt
  • Working with Room, SQLDelight, or Ktor in a layered architecture

Module Structure

Recommended Layout

``` project/ ├── app/ # Android entry point, DI wiring, Application class ├── core/ # Shared utilities, base classes, error types ├── domain/ # UseCases, domain models, repository interfaces (pure Kotlin) ├── data/ # Repository implementations, DataSources, DB, network ├── presentation/ # Screens, ViewModels, UI

(truncated - see the full file via the links below)

File tree — 1 file
skills/android-clean-architecture/SKILL.md

Let your AI agent find skills like this

Example. Real query, live index.

You found this page by searching. An agent finds it by wishing: SkillFed indexes 56,283 agent skills by what they can do, searchable in plain language.

wish › “Structure Android/KMP projects with clean architecture layers”

Give your agent the search over MCP, or paste the wish link into any chat. No install? Search from any chat →

Related skills

android-development
by travisjneuman · travisjneuman/.claude

Master Android development using Kotlin and Jetpack Compose for declarative UI building. Learn clean architecture patterns, dependency injection with Hilt, Room database integration, and Retrofit API calls across phones, tablets, TV, Wear OS, and Android Auto.

MITupdated Jul 2026
★ 85repo stars
kotlin-multiplatform
by travisjneuman · travisjneuman/.claude

This skill equips you to develop applications that run seamlessly across multiple platforms—Android, iOS, desktop, and web—by leveraging shared Kotlin codebases. Learn to structure projects for maximum code reuse while handling platform-specific implementations efficiently. Master the patterns and tools that make Kotlin Multiplatform a practical choice for teams building truly portable applications.

MITupdated Jul 2026
★ 85repo stars
kotlin-expert
by personamanagmentlayer · personamanagmentlayer/pcl

This skill leverages Persona Control Language (PCL) to deliver specialized Kotlin mentorship, covering everything from language fundamentals to advanced Android patterns and asynchronous programming with coroutines. Get personalized recommendations and solutions that adapt to your experience level and project needs.

Apache-2.0updated Mar 2026
★ 38repo stars
android-kotlin
by alinaqi · alinaqi/maggy

This skill equips you to develop Android applications using Kotlin's modern ecosystem. Leverage Jetpack Compose for declarative UI, Coroutines for asynchronous programming, and Hilt for dependency injection to create robust, maintainable mobile apps.

MITupdated Jul 2026
★ 703repo stars
compose-multiplatform-patterns
by affaan-m · affaan-m/ECC

Master patterns for building shared UI with Compose Multiplatform and Jetpack Compose across multiple platforms. Covers state management with ViewModels, type-safe navigation, reusable composable design, platform-specific implementations, and recomposition optimization.

MITupdated Jul 2026
★ 234,207repo stars
hexagonal-architecture
by affaan-m · affaan-m/ECC

Master the Ports & Adapters pattern to isolate business logic from frameworks and infrastructure. This skill covers domain modeling, use-case orchestration, inbound and outbound port design, adapter implementation, and composition wiring across multiple languages.

MITupdated Jul 2026
★ 234,207repo stars

More skills laravel-patterns (MIT)

Tags
layered-architecturemodule-boundariesdependency-inversiondata-mappingreactive-streamsstructured-concurrencysealed-typesmultiplatform-design