Group Group Group Group Group Group Group Group Group

raywenderlich.com Forums

Reactive Programming with RxAndroid in Kotlin: An Introduction

Learn about how Reactive programming is a whole new paradigm using RxJava and RxAndroid in Android with Kotlin.


This is a companion discussion topic for the original entry at https://www.raywenderlich.com/384-reactive-programming-with-rxandroid-in-kotlin-an-introduction

Thanks so much for this intro to Rx. The Excel spreadsheet analogy is great, it makes a complex mindshift to Rx easier to grasp.

Hi @igorganapolsky,
Thank you, @mlatu did an excellent job writing the original tutorial :]

Another question. Why have two .observeOn(AndroidSchedulers.mainThread()) in the subscription chain. Would mainThread be the default anyway?

@galata Can you please help with this when you get a chance? Thank you - much appreciated! :]

You invoke the debounce() function in the createTextChangeObservable(). By default, it operates on the computation thread. That’s why you need to explicitly define the execution thread as main, otherwise, you’ll get CalledFromWrongThreadException, as you can access Android views from the main thread only

1 Like

This tutorial is more than six months old so questions are no longer supported at the moment for it. Thank you!