wealthfront / magellan

The simplest navigation library for Android.
Apache License 2.0
677 stars 70 forks source link

Kotlin-sample #40

Closed jmfayard closed 6 years ago

jmfayard commented 7 years ago

Hello,

I had great success with building an android app with kotlin, leveraging magellan to get rid of activities and fragments, and the additional technique of abstracting the android widgets with delegated properties to make the android views even dumber : example here

Would you like me to contribute an additional sample?

Jean-Michel

fabiendevos commented 7 years ago

Hi @jmfayard ,

You totally can! Ideally, maybe start with something really minimal and simple. I am not really familiar with this technique but this looks really interesting.

Another option which might actually be much better is for you to have a sample in your own repo and I can link to it from the readme or the wiki! That way you can also update it and make it evolve as you want.

Let me know what you prefer,

Fabien

jmfayard commented 7 years ago

@fabiendevos

I would prefer if the sample could live inside the project, but a separate repo is better at first : I'm using android studio canary and beta versions of the android gradle plugin.

I already started, I chose to do a loose reimplementation of the android testing codelab

https://github.com/googlecodelabs/android-testing

My project is here

https://github.com/jmfayard/android-kotlin-magellan

I really like how everything combine. Navigation is a breeze, the android views are Simple and Stupid, mocking just work (kotlin classes are final, but no pb for Mockito with the right configuration!) making unit testing of the screens straightforward.

The two things I want to add next is documentation and instrumentation tests using Instrumentation Testing Robots

jmfayard commented 7 years ago

I added instrumentation tests using the testing robots Pattern

fabiendevos commented 7 years ago

This is really cool thanks!!!