GithubHelp home page GithubHelp logo

momintahir / kmp-news-app Goto Github PK

View Code? Open in Web Editor NEW
50.0 1.0 7.0 5.46 MB

This application demonstrates modern Android development with Koin, Ktor, Coroutines, Flows, SQLDelight, Voyager based on Clean Architecture.

Kotlin 98.63% Swift 1.37%
android android-app android-application android-architecture android-studio clean-architecture clean-code compose compose-multiplatform flows kmp kotlin kotlin-android kotlin-coroutines kotlin-language kotlin-multiplatform kotlin-native mvi-architecture mvvm mvvm-android

kmp-news-app's Introduction

💎 Compose Multiplatform - News App

Application Scope

This is a simple application that presents news information. The data is dynamically sourced from the News Api.

🗡️ This demonstrates modern Android development with Koin, Coroutines, Flow, Jetpack (Ktor, ViewModel), and Material Design based on Clean Architecture.

The app has a few screens located in multiple feature modules:

  • News list screen - displays list of News
  • News detail screen - display information about the selected news item
  • Favourites screen - display list of news item which are stored in local app database
  • Profile screen - empty (WiP)

Tech-Stack

This project takes advantage of best practices and many popular libraries and tools in the Android ecosystem. Most of the libraries are in the stable version unless there is a good reason to use non-stable dependency.

Architecture

KMP-News-App is based on the MVVM architecture and the Repository pattern, which follows the Google's official architecture guidance.

architecture

The overall architecture of KMP-News-App is composed of two layers; the UI layer and the data layer. Each layer has dedicated components and they have each different responsibilities, as defined below:

Pokedex was built with Guide to app architecture, so it would be a great sample to show how the architecture works in real-world projects.

Architecture Overview

architecture

  • Each layer follows unidirectional event/data flow; the UI layer emits user events to the data layer, and the data layer exposes data as a stream to other layers.
  • The data layer is designed to work independently from other layers and must be pure, which means it doesn't have any dependencies on the other layers.

With this loosely coupled architecture, you can increase the reusability of components and scalability of your app.

UI Layer

architecture

The UI layer consists of UI elements to configure screens that could interact with users and ViewModel that holds app states and restores data when configuration changes.

Data Layer

architecture

The data Layer consists of repositories, which include business logic, such as querying data from the local database and requesting remote data from the network. It is implemented as an offline-first source of business logic and follows the single source of truth principle.

KMP-News-App is an offline-first app is an app that is able to perform all, or a critical subset of its core functionality without access to the internet. So users don't need to be up-to-date on the network resources every time and it will decrease users' data consumption. For further information, you can check out Build an offline-first app.

Find this repository useful ? ❤️

Support it by giving a ⭐ to this repository.

Author - Momin Tahir

kmp-news-app's People

Contributors

momintahir avatar momin-tahir avatar

Stargazers

salman nazeer avatar Justin George avatar Regine Urtegård avatar Diego Beraldin avatar Swaminathan Manickavasagam avatar Ezinwa Victor avatar Miguel _ avatar RyuuyaS avatar Savas Pravia Vega avatar Arga Hutama avatar Hossam. avatar Sam King avatar purikazemieh avatar Lanlinju avatar  avatar Amit sahoo avatar Prasad More avatar  avatar Muhammed Elşami avatar  avatar Rodrigo Guerrero avatar  avatar Dennis Wanja avatar Jayant Kumar avatar  avatar  avatar Burhan Kamran avatar Sayan Bera avatar Muhammad Naveed avatar Jonibek avatar Juanjo Martí avatar </Saurav_Chandra> avatar  avatar Nav Singh avatar Jesus Garcia avatar Asad Waheed avatar Enam Kırgeç avatar  avatar  avatar Ricardo Trejos avatar Flavio Franco avatar Recep Güzel avatar Myo Thiha avatar  avatar Bastian Schwind-Wagner avatar Mehran Kasebvatan avatar Shahzad Ansari avatar  avatar Madhav Solanki avatar Khaled Eid 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.