GithubHelp home page GithubHelp logo

movies-db-android's Introduction

movies-db-android

This is a sample kotlin project to showcase a demo MVP Android project. It shows how different frameworks interact with each other on the MVP architecture.

Libraries

  • RxJava 2 (with Kotlin extensions)
  • Retrofit 2
  • Dagger 2 (for Dependency Injection)
  • SQLBrite (Reactive SQL queries)
  • Timber (logging)
  • Picasso (for image loading)
  • ThreeTenABP (JSR-310)
  • JUnit + Mockito (Unit tests)
  • Robolectric (Android SDK unit tests)
  • Espresso (Android UI tests)

Setup

This application uses The Movie DB API. You need to obtain an API key for the application before using it. Create a file named project-keys with the following line MOVIES_DB_API_KEY = "<YOUR_API_KEY>"

MVP/MVI

This project follows the Model-View-Presenter/Model-View-Intent architecture. You can read more about it here.

movies-db-android's People

Contributors

fmrsabino avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar

Forkers

shakil807g

movies-db-android's Issues

Tests

I read you blog posts, and I like this implementation of MVI/MVP with ModelView (Android arch component) and RxJava and state reducers to manage state (inspired by Jake Wharton's Presentation).
It would be nice to see also Unit Test sample as mentioned in Managing State with RxJava at 46:55
Testing Presenters (business logic of the app):
image

Unit Testing UI and how it renders different states:
This can be useful to see how to app looks like and behaves given a certain State (UI model)
image

Managing subjects

I'm from your article https://medium.com/@fmrsabino/an-approach-to-mvp-mvi-with-dagger-2-part-1-viewmodel-is-here-bdfc09c8732 and really thanks for that.
So I tried Jake's architecture but I can't manage those Observables well. I write a more detailed description in StackOverFlow : https://stackoverflow.com/questions/44826558/how-to-keep-part-of-observable-alive-regardless-upstream

I saw your code in this repo but I didn't find how you generate your UiModel from Ui(like button clicks?) except you have a RefreshEvent in the constructor of Presenter. How you solve the problem as I mentioned in StackOverFlow? Really appreciate your answer and sorry if I bother you to ask this question via Github issue.

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.