Ranter
Join devRant
Do all the things like
++ or -- rants, post your own rants, comment on others' rants and build your customized dev avatar
Sign Up
Pipeless API
From the creators of devRant, Pipeless lets you power real-time personalized recommendations and activity feeds using a simple API
Learn More
Comments
-
Good luck and keep us posted. Kotlin is on my list of things to learn. So I'd like to hear how it went. :)
-
@-psr There are 2 main reasons
1. I want to learn more about kotlin and I think changing my current code will help me understand it better
2. Kotlin has less boilerplate -
You can ignore lateinit warnings, they keep your code more organized, but not mandatory to use.
??variable is your friend. Use it. Refactor your logic if needed. It will be worth it.
Refactor your shitty workarounds caused by Java being such a jerk with nulls.
Use foreach returns, they are weird to use but absolutely a work of art if you are used to it.
Keep your static variables at the bottom, inside of a union class ( i name it like that, i forgot the whole thing ), for tidying purposes.
If you use something like Android Studio, it will recommend you that anyways.
Some code snippets are not easily converted to Kotlin, expect some hardships and a learning curve.
Related Rants
Going to refactor my whole android app from java to kotlin
Wish me luck!
rant
refactoring nightmare