Hacker Newsnew | past | comments | ask | show | jobs | submitlogin
Ask HN: Why isn't Kotlin getting enough attention on HN
5 points by lewisjoe on June 19, 2023 | hide | past | favorite | 9 comments
Is there a reasonable explanation for why Kotlin isn't getting enough 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 (compared to the hassle of writing the core in C/C++ and then hand-writing platform specific bindings)

2. Keen focus on enabling single codebase for multiple platforms.

3. The company went so far, as to build a multi-platform UI Framework (Compose Multiplatform) that directly renders to Skia and runs on all mobile/desktop platforms. And even on browsers (with wasm)

https://kotlinlang.org/docs/multiplatform.html

https://www.jetbrains.com/lp/compose-multiplatform/

I find it odd, that such interesting a language / compiler finds little attention beyond its domain.

Is there any reasons for this that I'm missing?



The features you describe in a way is what I see the biggest downfall.

The idea of Kotlin multiplatform itself is good, but I don't think Jetbrains as a company can sustain it. They're trying to do too much for their size and it shows. There are bits and pieces everywhere but they lack polish.

There's a lot of "Kotlin way" libraries, frameworks and language constructs that are all 1/2 backed. They either have bugs, missing enough features that you can't use it in a full project or get abandoned. It lost focus moving to multiplatform. Perhaps it'd be better if they focused back on being a better Java. Not to mention the Kotlin compiler is as slow as a snail. This is being worked on in 2.0, but for now and for a long time it's been terrible.

On the other hand Java has gotten stronger and caught up a lot. There's now less incentive for Java developers to migrate. The only big switch has been Google and Android. Whilst others have moved - those are all Java first frameworks with Kotlin "support". This arguable relies on the developer to somewhat know Java.

For non-Java developers - Kotlin is as hard to get into as Java. You need Intellij (the Jetbrains IDE), to install the JVM and work out Gradle (in Kotlin it's recommended vs Maven). This enough can be a showstopper for some. There are a lot of layers and hurdles before you can even "Hello World". For the some crowd, there are those that are anti Java / JVM and hence won't adopt it.

Likely a lot more pain points...

I wanted to like Kotlin a lot more and do, but it's not all perfect.


These are good points. In my opinion, Kotlin is easy to get into for anyone with some programming experience (not necessarily Java) and it is very well documented. The issue though is the tooling. Maven or Gradle is what's hard to get into, not Kotlin itself as a language. It sucks that there is such a barrier to just get things running. If there was a simple "rustup" or "cargo" like command that sets everything up imo. it would be more popular.


Kotlin does not produce machine executables. Kotlin produces JVM bytecode and JVM languages have not caught the attention of HN folks very frequently. Clojure comes up from time to time but I am sure that's because it is a Lisp which is discussed favorably by HN folks.

Both Zig and Rust fill important gaps in the programming languages. If someone wants a better C, they look at Zig. Zig is simple like C. It has less concepts, good memory management story and protects the developer from shooting their foot.

If someone wants a better C++, they look at Rust. Rust is complex but has strong memory safety guarantees.

Both Zig and Rust are great alternatives for C and C++ both of which have been used extensively in the IT. What gap is Kotlin fulfilling? What is Kotlin doing so well that another language cannot do today?


> What gap is Kotlin fulfilling?

Being a more fun-to-use Java? That's probably a big reason why it's done so well on the Android front AFAICT. But as you said, maybe JVM isn't that hot on HN

> Kotlin does not produce machine executables.

I haven't used KN before [0], but it does seem to do this. Overall, maybe Kotlin's "problem" is that it is tied to one ecosystem (native mobile development) which isn't as popular as web is.

[0] https://kotlinlang.org/docs/native-overview.html


> Being a more fun-to-use Java?

That's fine. What I meant earlier was that both Zig and Rust are filling a very important technical gap. Both Zig and Rust are solving memory safety issues in different ways. Java is already a memory safe language so the motivation to move from Java to Kotlin is not as strong as the motivation to move from C to Zig or C++ to Rust.


> Kotlin does not produce machine executables. Kotlin produces JVM bytecode

Strictly speaking - not true. JVM languages via GraalVM have been able to produce native executables for quite a while already. A lot of frameworks / libraries support this too.


You mean in comparison to Rust which is trending all the time? If we look back on comments for the last 30 days, Kotlin gets mentioned a lot,

https://hn.algolia.com/?dateRange=pastMonth&page=0&prefix=tr...

I think the issue is as you say, Kotlin is limited to a specific domain mostly. And I would also say that perhaps most people working with Kotlin are doing it for specific companies and aren’t as popular as Rust which is being used to port everything to it.


I feel like this is the only place I hear about Kotlin actually.


Except for the syntax which is a bit better imo, there's very little reason to use Kotlin over Java. Also it's very slow to compile, it's unnerving.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: