Skip to content

Starter project for android development with example.

Notifications You must be signed in to change notification settings

klinikpintar/ModularStarter

Repository files navigation

ModularStarter

A starter for modular android project.

Why Modular?

Going modular gives you lots of benefits such as :

  • Faster build time
  • Less coupling / dependencies
  • Flexibility to adopt different architecture for different module
  • On demand feature delivery using Dynamic Module

Structure & Concept

Main Modules

App

You can basically leave this one out. App Module is now as small as possible and only used as entry point.

Data

This is your module for your data source. Connect to your API, manage cache, creating entities happened here.

Features

Each feature must be contained in a separate gradle module.

Navigation

This is used for routing purposes, especially between modules.

Common

Contains reusable classes and resources that you can use in another modules. We have already added some useful common features that you will need to start your project.

How to Add New Feature

  1. Setup your data source, and update relevant build / android_commons gradle file. Add relevant functionality in data modules (model, local, remote, repository)
  2. Add your relevant features. Create new module for each feature
  3. Add your relevant features koin module and add them in App application.
  4. Connect your features by updating navigation module nav graph

THIS IS A WORK IN PROGRESS

TODO

  • Improve readme
  • Screenshots
  • Product flavors
  • Write Unit test and Instrumental test
  • Add recycler view example feature as Dynamic Module
  • More utils
  • Create project generator
  • Define style standard

Dependencies

Minimum Version

  • Android Lollipop (API 19) or above

App

  • Jetpack - Jetpack is a suite of libraries, tools, and guidance to help developers write high-quality apps easier.
  • Retrofit - A type-safe HTTP client for Android and Java
  • RxJava - a library for composing asynchronous and event-based programs by using observable sequences.
  • Koin - A pragmatic lightweight dependency injection framework for Kotlin developers. Written in pure Kotlin
  • OkHttp - HTTP is the way modern applications network. It’s how we exchange data & media. Doing HTTP efficiently makes your stuff load faster and saves bandwidth.
  • Room - Persistence library provides an abstraction layer over SQLite to allow for more robust database access while harnessing the full power of SQLite.

Test

  • MockK - mocking library for Kotlin.
  • MockWebServer - A scriptable web server for testing HTTP clients
  • Espresso - Concise, beautiful, and reliable Android UI tests.

About

Starter project for android development with example.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Contributors 3

  •  
  •  
  •