what is your preferred way today to use the new Architecture Components ?
Sandeep Srinivasa

I cant speak to the usage of architecture components because I dont use them, but my presenters define a ViewSurface and a RouterSurface interface and the calling Activity/Fragment/View will implement the view surface (and either also implement the router surface, or get it from another source eg a fragment’s parent activity may handle routing), which is passed to the presenter upon creation. So a simplified flow might look like sampleButton.setOnClickListener { presenter.onDoTheThing() }and then the presenter would call fun onDoTheThing() { router.navigateToSomePlace() } or fun onDoTheThing() { sampleUseCase.updateSomething().subscribe { view.showTheResult() } }

One clap, two clap, three clap, forty?

By clapping more or less, you can signal to us which stories really stand out.