Giter Club home page Giter Club logo

modular's Introduction


kmm

Kotlin Multiplatform Mobile - Modular Project Example


Overview

The standard KMM project template created in Android Studio consists of a single shared module, an iOS client project, and an Android client project. This is a great way to get started using KMM, but depending on your project needs, could become cumbersome to maintain as your project grows in size and complexity.

This repo is a sandbox for me to experiment with using a modular approach, which follows an 'umbrella structure' consisting of a single point of reference for our client projects (i.e. the shared module), with separate submodules for networking, database, utilities and features:

kmm

But why?

There are a lot of benefits to this approach, including:

  1. Manageability - Having a project separated into smaller pieces allows for easier management as complexity increases. The separate modules enable developers to work on the project in parallel. In addition, modules can be loaded / unloaded as needed.

  2. Extendability - It's much easier and cleaner to create a new submodule to support a new feature, as opposed to implementing it within an individual application. As requirements change, having an independent module allows for much more flexibility.

  3. Testing and Errors - Having functionality isolated means we can also test and identify errors on the module level, which simplifies fault detection and reduces risk.

  4. Reuse - The submodules can easily be reused as a dependency in another project if business or product needs change.

Plans

This is an ongoing work in progress, but I plan on adding example code for the following:

  1. Networking example with Ktor.
  2. Local persistence example with Realm.
  3. Testing and CI examples.
  4. Publishing as a consumable library.

modular's People

Contributors

ninehundreds avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.