Which Javascript framework would you choose for a ...
# javascript
n
Which Javascript framework would you choose for a new project? KVision/Fritz2/React/something else? Thanks,
r
I would choose KVision, but I'm not objective ๐Ÿ˜‰
๐Ÿ˜„ 9
t
A lot depends on the type of project. How much your UI needs to be customized vs how much tim are you willing to spend on UX. I can warn you that kotlin wrapper for React is not well maintained. It's well written, but has a few not addressed bugs. Also a lot of features does not work with IR compiler.
๐Ÿ‘๐Ÿป 3
b
I've tried all three and loved fritz2 with bootstrap css best. Mainly due to it being 100% kotlin and not having any js dependencies (allowing me to keep my hands clean off js)
๐Ÿ‘๐Ÿป 2
KVision is nice and updated regularly, however it has quite a few js dependencies
๐Ÿ‘๐Ÿป 1
r
Core KVision dependencies are kotlinx.serialization, snabbdom, jquery and a few others small JS libs. Fritz2 depends only on kotlinx.coroutines. But coroutines library adds a lot more to the final bundle size.
For the same app (todomvc) for KVision (even with additional Redux module) we have 650KB and for Fritz2 - 750KB.
The smallest KVision app is 440KB. The smallest Fritz2 - 630KB.
But of course for larger apps it will be less noticeable, especially when you use coroutines with KVision and serialization with Fritz ๐Ÿ™‚
b
Yeah, KVISION does go miles when aiming for small bundle size. I have no clue where you find so much patience to keep running around coroutines for so long, @Robert Jaros ๐Ÿ˜€
r
We have to share the same universe with Svelte ๐Ÿ˜‰ We just need to take the bundle size seriously ๐Ÿ™‚
I love coroutines and I use them with almost all my apps ๐Ÿ™‚
b
Everyone does! It's sad that they're unsuitable for small apps :/
r
As for fritz2 - for me it's very interesting framework and I took some inspiration from it developing latest KVision releases. In fact, you can now very easily develop KVision apps with very similar concepts. But still, I can't imagine working easily with more complex Fritz2 data models. For me it's definitely easier to just use the state as a whole and not have to partition it with substores and lenses for every view element.
๐Ÿ‘๐Ÿป 1
n
The smallest Fritz2 app is 552 KB. Fritz2 is the easiest web framework to go with, which doesn't rely on any major JS framework/library (aka the pure Kotlin approach), and uses many existing concepts that Kotliners already know.
Why is the the Kotlin team not developing a heavily optimized version of the KotlinX Coroutines library for Kotlin JS?
b
Because this problem will likely go away once they figure our ES6 support
๐Ÿ˜ฎ 1
a
such an informative thread
152 Views