Zhuinden / simple-stack

[ACTIVE] Simple Stack, a backstack library / navigation framework for simpler navigation and state management (for fragments, views, or whatevers).
Apache License 2.0
1.36k stars 76 forks source link

simple-stack-example-mvvm-fragments on kotlin having some error #205

Closed androuino closed 4 years ago

androuino commented 4 years ago

I am following the example on this simple-stack-example-mvvm-fragments project but in Kotlin, so basically what I did is converted the classes from Java to Kotlin, however if I run the app, am getting this error: https://gist.github.com/androuino/99d8075ad1604ea1d81c16252727409c and this is the sample of my FragmentStateChanger.kt class: https://gist.github.com/androuino/2242587497843ce1084e1ea61e9dc4be at this class, the line that says fragment.bindViewModel() is being captioned as Unreachable code. And now this is my BaseFragment.kt class: https://gist.github.com/androuino/c99090e67b870ceab3a8ed4e3dd85ca1

Thanks for the help guys.

androuino commented 4 years ago

Never mind, I've finally got it working.