Live data from Hacker News

Kotlin Multiplatform for Android and iOS Apps

rockandnull.com

41–50 of 82 posts

Re: Kotlin Multiplatform for Android and iOS Apps

#41
post #21

I really don't get the appeal of "multiplatform" rediscoveries. We already have the Multiplatform stack that is mature and truly Multiplatform: HTML+JS+CSS If you need something close to the metal, you have C and others that are multiplatform. If you want to do something slightly platform specific you loose the multiplatform claim instantly anyway. IMHO, if you are going to do something that is not an UI to an API or…

In KMM multiplatform means Kotlin code can directly interoperate with Swift on iOS or Java on Android. HTML cannot do these things.

Re: Kotlin Multiplatform for Android and iOS Apps

#42

I'm puzzled why Kotlin isn't getting enough attention on HN, at least as much as Rust or Zig. Kotlin is indeed popular in it's specific domain (Android & Java). But the company is keen to position it as "write once run anywhere" space with a strong focus on multiplatform development. 1. The build system provides platform specific bindings for free (huge plus compared to the hassle of writing the core in C/C++ and the…

I use Kotlin daily at my job (I have to) and I'm not impressed. It is a new language that ignores most of the innovations in Programming Language Theory from the last 20 years. It only improves on Java by making the syntax less verbose and adding coroutines but almost doesn't add any benefits in terms of semantics.

Re: Kotlin Multiplatform for Android and iOS Apps

#44

I'm puzzled why Kotlin isn't getting enough attention on HN, at least as much as Rust or Zig. Kotlin is indeed popular in it's specific domain (Android & Java). But the company is keen to position it as "write once run anywhere" space with a strong focus on multiplatform development. 1. The build system provides platform specific bindings for free (huge plus compared to the hassle of writing the core in C/C++ and the…

iOS dev here. What you're missing is that a ton of native-code developers (me included) aren't interested in adopting an abstraction layer that has to be tweaked to approximate the look and feel of the native OS UI layer when we could just built it natively to begin with and save all that effort. We've seen PhoneGap/Cordova, we've seen React Native and we'll keep seeing money thrown away on pretending that there aren…

The idea is you can write SwiftUI on iOS, whilst connecting to business logic written in Kotlin.

Re: Kotlin Multiplatform for Android and iOS Apps

#45

iOS devs don't want to use Kotlin multiplatform, I really doubt this will gain any traction.

As an iOS user, I also don’t want to use Kotlin Multiplatform, as it breaks my muscle memory and behaves just so slightly differently that it is enough to be annoying.

Same goes for any other multi platform GUI.

Re: Kotlin Multiplatform for Android and iOS Apps

#47
The downside of this approach, like most other multiplatform approaches, is that it disadvantages the web which is the platform most sensitive to code size and accessibility concerns.

Compose Multiplatform requires WASM (with GC!). This is going to require a Kotlin runtime plus Skia bundled in the WASM, probably with large parts of the standard library, and draw everything to the screen with canvas. Like Flutter apps, these apps will not load fast and will probably have accessibility issues.

Re: Kotlin Multiplatform for Android and iOS Apps

#48

I'm puzzled why Kotlin isn't getting enough attention on HN, at least as much as Rust or Zig. Kotlin is indeed popular in it's specific domain (Android & Java). But the company is keen to position it as "write once run anywhere" space with a strong focus on multiplatform development. 1. The build system provides platform specific bindings for free (huge plus compared to the hassle of writing the core in C/C++ and the…

iOS dev here. What you're missing is that a ton of native-code developers (me included) aren't interested in adopting an abstraction layer that has to be tweaked to approximate the look and feel of the native OS UI layer when we could just built it natively to begin with and save all that effort. We've seen PhoneGap/Cordova, we've seen React Native and we'll keep seeing money thrown away on pretending that there aren…

As an Android developer that's been using Compose and multiplatform I believe the play is to get Android developers to be able to minimally adapt their apps to run on iOS. They don't pretend that you don't need to know anything about iOS but are trying to abstract as much (or as little) a way to compile to both.

The other multiplatform attempts failed because they were trying to use languages that neither side wanted or knew and pretended like you could drop in a dev from a completely different field and not need to know much about the platforms. If you did know the platform you were fighting against the framework in an unfamiliar language.

That said it is definitely not there yet, but I hope they get it to a reasonable place. I've enjoyed Android development and would love to be able to more simply port over a project without a complete rewrite.

Re: Kotlin Multiplatform for Android and iOS Apps

#49

Kotlin is a Google project that wants to be cross platform, write once run everywhere. So is dart/flutter. I feel dart is further along on this. Seems a little silky having 2 projects aimed at the same thing?

Kotlin is not a Google project. It is made by JetBrains. It says so right up front on their web page: https://kotlinlang.org/

Re: Kotlin Multiplatform for Android and iOS Apps

#50
post #21

I really don't get the appeal of "multiplatform" rediscoveries. We already have the Multiplatform stack that is mature and truly Multiplatform: HTML+JS+CSS If you need something close to the metal, you have C and others that are multiplatform. If you want to do something slightly platform specific you loose the multiplatform claim instantly anyway. IMHO, if you are going to do something that is not an UI to an API or…

> We already have the Multiplatform stack that is mature and truly Multiplatform: HTML+JS+CSS

And that translates to Electron on the desktop environment and a webview on mobile devices I guess?

How is that better than Flutter for example? With Flutter, I am able to write once and compile to all platforms.

Post reply on HN