Pro Yearly is on sale from $80 to $50! »

Hello Worlds: A full-stack demo in Multiplatform Kotlin

Hello Worlds: A full-stack demo in Multiplatform Kotlin

7edddae207b212e5e035133d9eb10b82?s=128

Russell Wolf

November 09, 2019
Tweet

Transcript

  1. Hello Worlds A full-stack demo in Multiplatform Kotlin Russell Wolf

    11/9/19
  2. Background

  3. Kotlin is ... • Android • Server-side JVM • JS

    (frontend or node) • Native (C interop) • iOS (Obj-C interop)
  4. Multiplatform Kotlin • Compile common code to multiple targets •

    JVM, JS, Android, Desktop, iOS, Embedded, WASM • Use platform-specific code to access platform APIs
  5. Multiplatform Hello World • https://github.com/russhwolf/ multiplatform-hello • Android, iOS, Server

    • ktor, serialization, coroutines
  6. Hello Common
 Android
 iOS
 JVM
 Swift

  7. Hello Shared Common
 Android
 iOS
 JVM
 Swift

  8. Hello Shared Server Common
 Android
 iOS
 JVM
 Swift

  9. Hello Mobile Shared Shared Server Common
 Android
 iOS
 JVM
 Swift

  10. Hello Mobile Shared Android App iOS App Shared Server Common


    Android
 iOS
 JVM
 Swift
  11. Code time!

  12. Lessons • Shared models between frontend and backend • Shared

    web calls between mobile clients • Kotlin Everywhere!
  13. Thanks! • Questions? • @RussHWolf ( or )
 • https://github.com/russhwolf/multiplatform-hello


    • https://kotlinlang.org/docs/reference/multiplatform.html • https://kotlinlang.org/docs/reference/building-mpp-with- gradle.html • https://play.kotlinlang.org/hands-on/overview