What Kotlin technologies and frameworks is JetBrai...
# announcements
m
What Kotlin technologies and frameworks is JetBrains Space based on? Is it really already possible to build a large web project in Kotlin without going nuts? 😁 (The more I use JS/TS & React/Vue/Angular the more I’m going crazy…)
s
Looks like it uses Kotlin Multi Platform https://link.medium.com/LNeV0JFIk8
👍 1
m
Yes, but even with MP it still needs a proper web framework for example.
You don’t want to manually put HTML together for example 😁 Something like React, but made for Kotlin.
b
Kotlin has react dsl provided and maintained by jetbrains (which in my opinion is much better than jsx)
For state management there's js redux kotlin bindings as well or reduxkotlin lib which us a full redux port to kotlin #C8A8G5F9Q
I'm also working on full kotlin vdom lib for wasm and js #CNR7ARJGJ
r
m
Yeah, looks like they’re using React for Spaces! 🙂

https://www.youtube.com/watch?v=JnmHqKLgYY4&list=PLQ176FUIyIUY6SKGl3Cj9yeYibBuRr3Hl

b
#CL4C1SLKC for questions :)
m
Do I understand that right that KVision and KVDOM basically try to recreate React’s approach from scratch, but 100% Kotlin?
b
Not quite
m
hmm, KVision seems to be imperative. Aren’t we all moving past that? 😅
b
Kvision is object oriented high level web framework, whereas kvdom is essentially a lift and shift of snabbdom - low level vdom implementation
In theory kvision could eventually replace snabbdom with kvdom for vdom rendering and diffing
Anyways, if you want something stable, go with kotlin react as that fully integrates with js react ecosystem
r
KVision is imperative by design, but also supports DSL and declarative UI building with observable data models and unidirectional data flow
b
If you're adventurous, do try out kvision. It's a blast to work with!
m
Thanks for all the info. So much to learn! Anything that helps getting rid of JS and TS is worth working on though 😁
💯 1
👍 1
r
KVision is definitely stable as well :-)
b
In short, here's how kotlin libs maps to js alternatives from use-case perspective: * React = kvision * Snabbdom = kvdom
r
KVision large webapps are running smoothly in production for some time.
m
Thanks 🙂 Is there any article that compares KVision and (Kotlin-)React?
r
I don't think so
b
My bad, misused the word stable there. I meant to say that kotlin react is the way to go if you want a stable and tested ecosystem since it can tap into whole react.js world
@Robert Jaros I think kvision and react comparison article on medium would be a very hot topic. Please give it a go when you have some time to spare
m
I also tend towards kotlin-react for the start since anything that has JetBrains behind that has a much higher chance of getting pushed forward :)
They must have a lot of Kotlin developers there! Just watching that video was like “it sounds like a project with several dozen of developers involved” 😮
r
It's hard to compete with a product supported by Kotlin creators 😉 But in my humble opinion if you just want to have many ready to use components, KVision is way easier to work with.
b
Plus kvision is full on kotlin, whereas kotlin-react is just kotlin bindings and depends on react.js under the hood
r
@Big Chungus I probably wouldn't be able to do fair comparision, because I have never used React with plain JS 🙂
😢 1
m
Yeah, I’ll probably have to spend a lot of time digging into both to really understand the pros and cons and how day-to-day development feels like.
b
If you're pushing kotlin js to a company, you'll definitely have an easier sell with kotlin react.
r
You need to know React very well to work with kotlin-react.
m
No need to sell as I make the decisions. But I’ve got burned a lot by Kotlin Multiplatform once (that was mobile though), so I’m way more careful now 🙂
I only know Vue.js and Angular a lot by now and little React. I hope that the knowledge can be easily transferred though 😉
b
I see what you mean. MPP is still experimental after all. I'd suggest trying to write simple webapps (todo list maybe?) on both and see what issues you face.
r
But you can easily work with KVision, if you know any typical UI library from non-web world (e.g. Swing, QT, Winforms)
b
Bonus points for kvision, though, since it being mostly kotlin potentially will allow it to support webassembly once it's reworked by jetbrains
👍 1
m
What’s your experience with debugging when using either kotlin-react or KVision? That was often a big problem with Kotlin MPP.
b
Never had any. It's plain js source map debugging afterall
m
Breakpoints, variable inspection etc all working?
In mobile MPP I had to resort to
println()
😵
We need a social network for Kotlin where every developer can show their preferred stack and improve it over time 😄
b
It might take some time getting used to filtering out kotlin properties noise attached to your object by the compiler, but basic stuff like breakpoints, scopes, variable inspection works the same as for js
👍 1
m
noise is fine
b
For your mpp issue I'm guessing you didn't have a good time on ios side of things, since android is a first-class citizen on kotlin
m
Yeah, Android is a lot easier. Although I kept switching between IDEA and Android Studio…
b
Ah, i hate that you cannot use idea for Android anymore... Drives me nuts when working on MPP
m
Basically IDEA, Android Studio and AppCode in one IDE would be amazing 🙂
b
But since android studio is idea based I'd expect it to support android and common source sets in the near future
AppCode is OS locked, so i wouldn't expect being able to get rid of it anytime soon...
m
It could still be an OS-specific plugin for IDEA instead of its own IDE.
Like I use PHP without PhpStorm
b
Best case we'll get ios idea supporting android and iOS, but still requiring both android studio and app code installed on the machine
m
Yes, or something like that.
I’ll dabble with kotlin-react and kvision at some point as a basis for a CRM I’m working on and figure out if it’s a good option. Back-end is all Kotlin & GraphQL but front-end is still a Vue.js mess.
Another problem is finding other developers who can actually work with that. It’s much easier to find a React developer than a kotlin-react or KVision developer.
Anyone interested in GraphQL btw? I’m still looking for some help with my GraphQL library 😛
b
There's also #C8CQT4F47 for kotlin :D
m
I guess that makes finding a developer for that even more difficult 😛
b
Never worked with graphql myself, sadly /disappointed:
m
I disliked it at first. After using it for a while, I do now dislike normal HTTP REST 😁
b
Finding a non-android kotlin developer is difficult in general 😀
m
true
Maybe they all work for JetBrains by now 🤔
b
Yeah, I keep hearing great things about graphql, just didn't have the opportunity to try it out myself yet
Well kotlin is still young, especially MPP
m
I’m surprised that the Gradle plugin says that Kotlin MPP plugin will be mandatory with Kotlin 1.4
Given that it’s still so buggy
b
And android announcing it as main language grabbed a bigger part of kotlin developers from the pool
Same thing happened when they removed kotlin native plugin while mpp was even buggier
r
There is 31K kotlin developers on #C0922A726 channel and only 28K on #C0B8M7BUY 😉 That's 3K non-android kotlin developers to choose from 😉
m
I’m also in #C0B8M7BUY but rarely work on Android apps 😛
b
But that allowed them to develop native much faster as there was just one less plugin to support
👍 1
I personally would prefer them dropping all gradle plugins and focusing on finally fleshing out MPP plugin
m
I’d also be fine with that if it doesn’t break existing projects
b
Since if you can use mpp plugin for mpp project you automatically can use that for non mpp
m
Like almost everything that uses composite builds
They should make Spaces open source (or at least share the source without allowing its use) so that we can use it as a reference for how to implement such a complex product 🤔
b
m
Nice, thanks
btw, any specific reason you use GitLab instead of GitHub?
b
Take them with a big grain of salt, though, as I've written them both nearly a year ago
Gives much much more free stuff for open source than github
And has a lot of other neat features other than being just a repo
m
What features for example?
b
The only downside is that github is pretty much a norm for open source these days...
r
using gitlab instead of github is just like using kvision instead of kotlin-react 😉
😄 2
b
Ci cd, container registries, kubernetes integration, environment monitoring, dependency and security scanning, auto devops just to name a few I'm using myself, but there's a lot more
Good point, Robert 😀 sneaky ad there
m
Monitoring sounds good 🙂 Kubernetes I’ve never used or needed. CI/CD, registries, security scanning is available on GitHub too.
b
Also i love gitlab's web IDE. Very useful when you're on the go without work laptop
👍 1
Yes, github has most of gitlab features too, but I'm not a fan the way github implemented some of them. Ci cd, for example is not managed by github, but rather delegated to external service like circle ci
m
They do have their own by now (GitHub Actions)
b
Just different approaches i guess. Github aims to be hackable, wheres gitlab provides in-house solutions
m
So many choices these days 😵
b
Just give gitlab a go and see how you like it. I don't think theres a hard deciding factor to pick one over the other.
m
Yeah, if there’s not at least one big convincing reason then I’ll stick with what everyone is using
b
You might find one that convinces you specifically. Just live with it for a month for two. Also it allows you to mirror githib repos, so you can try it without any impact on your flow
👍 1
For me, I just found gitlab much easier to manage and work with