This project template makes it easy to get started with Kotlin in Android development. It provides a python script that can generate a new Android project using Kotlin/MVP/ReactiveX. Just paste and execute the following command at a terminal prompt (it depends on the
python -c "$(curl -fsSL https://raw.githubusercontent.com/nekocode/Kotlin-Android-Template/master/project_generator.py)"
If you're using python 3:
python -c "$(curl -fsSL https://raw.githubusercontent.com/nekocode/Kotlin-Android-Template/master/project_generator_python3.py)"
This project demonstrates a basic Model-View-Presenter (MVP) architecture. It uses headless Fragment to implement Presenter because the Fragment provides lifecycle callbacks and can be recreated automatically by the FragmentManager. And the project entirely separates the business logic code into a submodule so you can maintain and test them separately.
This project uses the router APIs (UIRouter.kt) generated by Meepo to navigate between Activities. You can call these APIs directly in the Presenter just like here. And this project uses Robolectric to test the data services (/bussiness logic). Check the GankServiceTest.kt for more detail.
Feel free to contribute to this project by either raising issues or handing in pull requests.