Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/Ezike/StarWarsSearch-MVI
Star wars sample android project showcasing the use of View components for rendering UI in Fragments and Activities. Uses Android Jetpack, clean architecture with MVI (Uni-directional data flow), dagger hilt, and kotlin coroutines with StateFlow
https://github.com/Ezike/StarWarsSearch-MVI
android android-studio architecture clean-architecture componentization coroutines dagger-hilt flow jetpack jetpack-android kotlin kotlin-coroutines kotlin-gradle-dsl mvi mvi-android mvi-clean-architecture netflix redux redux-store viewmodel
Last synced: 2 months ago
JSON representation
Star wars sample android project showcasing the use of View components for rendering UI in Fragments and Activities. Uses Android Jetpack, clean architecture with MVI (Uni-directional data flow), dagger hilt, and kotlin coroutines with StateFlow
- Host: GitHub
- URL: https://github.com/Ezike/StarWarsSearch-MVI
- Owner: Ezike
- License: apache-2.0
- Created: 2020-09-09T16:41:42.000Z (over 4 years ago)
- Default Branch: main
- Last Pushed: 2024-04-14T11:45:38.000Z (9 months ago)
- Last Synced: 2024-08-03T17:11:06.096Z (6 months ago)
- Topics: android, android-studio, architecture, clean-architecture, componentization, coroutines, dagger-hilt, flow, jetpack, jetpack-android, kotlin, kotlin-coroutines, kotlin-gradle-dsl, mvi, mvi-android, mvi-clean-architecture, netflix, redux, redux-store, viewmodel
- Language: Kotlin
- Homepage:
- Size: 825 KB
- Stars: 197
- Watchers: 8
- Forks: 30
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
- awesome-android-kotlin-apps - StarWarsSearch-MVI - directional data flow), dagger hilt, and kotlin coroutines with StateFlow</br></br> <b>Tech Stack</b> : Jetpack, Dagger hilt, Coroutines & StateFlow, Room, Retrofit, FlowBinding </br></br> <i> Last commit: 2 months ago</i> | π 197 </br> π΄ 29 </br> ποΈ 8 | (:art: Pattern / MVI)
README
![Android Build](https://github.com/Ezike/StarWarsSearch/workflows/Android%20Build/badge.svg)
Hey there ππΌππΌππΌ
This project contains an implementation of the Componentization idea as shown by the UI Engineering team at Netflix.
Resources: [blog](https://netflixtechblog.com/making-our-android-studio-apps-reactive-with-ui-components-redux-5e37aac3b244), [repo](https://github.com/julianomoraes/componentizationArch), [talk](https://www.droidcon.com/media-detail?video=362740979)
## Features
* Clean Architecture with MVI (Uni-directional data flow)
* View components
* Kotlin Coroutines with Flow
* Dagger Hilt
* Kotlin Gradle DSL
* GitHub actions for CI## Prerequisite
To build this project, you require:
- Android Studio Jellyfish
- Gradle 8.3
- Kotlin 1.9.23
- Android Gradle Plugin 8.2.0Run the following command in the root of the project to setup your Android Studio:
```
./setup.sh
```
This script will configure [ktlint](https://github.com/shyiko/ktlint)Screenshots
## Libraries
- [Viewmodel](https://developer.android.com/topic/libraries/architecture/viewmodel) - Presenter for persisting view state across config changes
- [FlowBinding](https://github.com/ReactiveCircus/FlowBinding) - converts traditional view click listeners and call backs to Kotlin flow
- [Room](https://developer.android.com/training/data-storage/room) - Provides abstraction layer over SQLite
- [Retrofit](https://square.github.io/retrofit/) - type safe http client and supports coroutines out of the box.
- [Moshi](https://github.com/square/moshi) - JSON Parser,used to parse requests on the data layer for Entities and understands Kotlin non-nullable and default parameters
- [okhttp-logging-interceptor](https://github.com/square/okhttp/blob/master/okhttp-logging-interceptor/README.md) - logs HTTP request and response data.
- [kotlinx.coroutines](https://github.com/Kotlin/kotlinx.coroutines) - Library Support for coroutines,provides `runBlocking` coroutine builder used in tests
- [Truth](https://truth.dev/) - Assertions Library,provides readability as far as assertions are concerned
- [MockWebServer](https://github.com/square/okhttp/tree/master/mockwebserver) - web server for testing HTTP clients ,verify requests and responses on the star wars api with the retrofit client.
- [Robolectric](http://robolectric.org/) - Unit test on android framework.
- [Espresso](https://developer.android.com/training/testing/espresso) - Test framework to write UI Tests
- [Dagger Hilt](https://dagger.dev/hilt) - handles dependency injection
## License```license
Copyright 2020-2021 Ezike TobennaLicensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License athttp://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
```