Giter Site home page Giter Site logo

alvaroq / rickandmorty Goto Github PK

View Code? Open in Web Editor NEW
2.0 1.0 1.0 6.44 MB

An example Android Application that follow up Clean Architecture principles using MVVM pattern with Google architecture components, jetpack compose, dagger HILT, Error Handling, State-FLOW, detekt with kotlin.

Kotlin 100.00%

rickandmorty's Introduction

Rick and Morty Android App ๐Ÿ“ฑ

Platform JetpackCompose Hilt Detekt License Bitrise

The purpose of this project is to reflect knowledge in Kotlin of MVVM pattern, coroutines, Flows, dagger hilt injector, Room with SQLite and COMPOSE! using https://rickandmortyapi.com/ public api.

banner

Kotlin - Clean Architecture following SOLID and MVVM ๐Ÿ’ป

Single Responsibility Principle, Open/Closed Principle, Liskov Substitution Principle, Interface

Segregation Principle and Dependency Inversion Principle

Use cases with a CharacterRepository with Character and Local data sources

Dependency management with Kotlin kts and Kotlin Symbol Processing (KSP)

Dagger Hilt dependency and Error handling with Arrow library.

clean_architecture

Modules ๐Ÿ“‘

  • ::app - The application module with access to all the application
  • ::data - Android module that can only access domain module
  • ::domain - Kotlin module that cannot access any other module
  • ::usecases - Android module that can only access data and domain modules

Compose ๐ŸŒ€

Jetpack Compose and Compose Navigation

CollapsingLayout, HorizontalPager and two tabs Enter and exit transition with slide horizontally
collapsing_and_horizontal_pager transition
Scale animation on enable favorite button Showing cards sequentially on LazyColumn
expand_fav sequentially_cards

Multi-filter with pagination โšก

Filtered results with Status (All/Alive/Dead/Unknown), Gender(All/Female/Male/Genderless/Unknown) and naming with scroll-end pagination.

clean_architecture

Local storage ๐Ÿ’พ

Room store favorite on data base SQLite. I use the Entity 'Character' to save the characters selected as favorites by the user and I manage queries in DAO FavoriteCharacterDao.

Theme โ˜€๏ธ / ๐ŸŒ›

Dark and light depending system theme


@Composable
fun RickAndMortyTheme(darkTheme: Boolean = isSystemInDarkTheme(),content: @Composable () -> Unit) {
    val colors = if (darkTheme) {
        DarkColorScheme
    } else {
        LightColorScheme
    }
}

Analysis tool ๐Ÿ’Š

Detekt code analysis tool

Detekt

Libraries ๐Ÿ“–

  • Compose Toolkit for building native UI (in a declarative way - 100% Kotlin).
  • Compose Navigation for tabs navigation using Jetpack Compose.
  • Material3 The next evolution of Material Design. Material 3 includes updated theming and components.
  • Coroutines Library support for Kotlin coroutines.
  • Flows Stream processing API, built on top of Coroutines.
  • Dagger Hilt Dependency injection library for Android.
  • Retrofit Type-safe REST client for Android to consume RESTful web services.
  • Coil Compose Image downloading and caching library supported by Jetpack Compose.
  • Lottie Compose Library that provides that parses Adobe After Effects animations exported as json with Bodymovin and renders them natively on mobile.
  • Arrow Functional programming to Kotlin.
  • OkHttp3 Third party library for sending and receive network requests.
  • Room The Room persistence library provides an abstraction layer over SQLite to allow for more robust database access while harnessing the full power of SQLite.
  • Detekt Static code analysis tool for the Kotlin programming language.

License ๐Ÿ“„

Copyright 2023 Alvaro Quintana
Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. 
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
http://www.apache.org/licenses/

Buy Me A Coffee

rickandmorty's People

Contributors

alvaroq avatar

Stargazers

Driss Bounouar avatar ElenaGrigoruta avatar

Watchers

 avatar

Forkers

herrbert74

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.