GithubHelp home page GithubHelp logo

amitshekhariitbhu / kotlin-coroutines-android-examples Goto Github PK

View Code? Open in Web Editor NEW
1.0K 40.0 261.0 484 KB

Moved to https://github.com/amitshekhariitbhu/Learn-Kotlin-Coroutines

Home Page: https://github.com/amitshekhariitbhu/Learn-Kotlin-Coroutines

License: Apache License 2.0

kotlin-coroutines-android-examples's Issues

Handle network exception in data layer

In this project, the network exceptions are handled in ViewModel and it's not a good approach. How can we handle network errors such as 404, 500, etc inside of the repository?

Api calls in viewModelScope (Dispatcher.Main)

For reference: ViewModel.kt

I see you are using viewModelScope for API calls without switching the context.
viewModelScope uses Dispatcher.Main, so it is not appropriate to directly launch the coroutine. It should be viewModelScope.lauch(Dispatcher.IO){ //api calls }

Please correct me if I'm wrong.
Thanks for the repo.

Mutliple table handling make an issues

I working with the pattern which is more helpful and reduces half of work in my project. But when i am dealing with multiple table handling, it doesn't let me to do. can please suggest me any solution?

How to handle no internet connection

Thanks for this great project

I tried your code, but its show whole IP address of API, but I want to show only "no internet connection when there is no internet connection"

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.