Android Jetpack: sweetening Kotlin development with Android KTX (Google I/O ’18)

Google+ Pinterest LinkedIn Tumblr +



This talk introduces Android KTX, which is the new set of Kotlin extensions for Android. It demonstrates how Android developers writing Kotlin can use Android KTX to make their code more idiomatic, concise, and pleasant. It will also discuss how developers can make their own libraries more Kotlin-friendly.

Watch more Android sessions from I/O ’18 here →
See all the sessions from Google I/O ’18 here →

Subscribe to the Android Developers channel →

#io18

Share.

About Author

25 Comments

  1. onApi can return a class which has the functions orApi() and orNull() another possibility would be to return null or the returnvalue of the language and the last option would be to return Unit?

    This would however only feel good to me if the body of the method would be an specific context like ApiContext to which multiple functions are attached that can only be called from that specific body. In that case you would really use the type-safe builders, but I think this approach doesn't entirely match the other extension-functions.

  2. new to android development, would you tell me which should I go learn Kotlin with android studio plus ktx, or should I go flutter with dart, google is confusing new comers like me, I felt it is a dilemma for me to even start learning it.

  3. it was java then , why java ? and then people moved to kotlin , then why kotlin , lets go for flutter , then why i/o released new updates to Android kotlin , since the flutter will be taken place next years , can anyone tell me why should i learn jetpack, people are going to move to web development since there is no stability in coding platform.

  4. When should we create extensions? are they worth the effort to use them only once or should they be used more times to worth it?

    Also

    Is it there a hard rule to use inline or not? I´ve read you should use it on small functions, but how can we define "small", until 4 or 5 lines of code?