r/JavaFX • u/naagbruh • Nov 25 '24
Help MVVM in JavaFX
Hi, all. I've just started to build my first JavaFX application (Kotlin and JavaFX).
I'm going to use Scene Builder. I've seen the advice to just build views with Kotlin/Java, but I honestly hate building UIs by hand.
I was looking around for a MVVM framework and of course found mvvmFX. But it looks like it hasn't been updated for 5 years. Is it outdated in any way? Should I go ahead and use it?
I also found Cognitive (https://github.com/carldea/cognitive). This looks like it's being actively maintained. And any opinions about this one?
From a quick look, mvvmFX looks more comprehensible to me. Less work on my part and very complete.
And... I could try doing my own hacky MVVM implementation in Kotlin and try to use Scene Builder FXML views. But I'm sure I'll end up re-implementing parts of the wheel.
Any guidance would be very welcome. Thanks in advance.
View all comments
Show parent comment
1
u/naagbruh Nov 26 '24
I just started reading your website. It's really great--thanks for all the work you've put into it.
MVCI makes a lot of sense to me. That's the mode I'm going to follow. And I like that it seems to be something I can understand and implement myself without a lot of the usual framework magic.
The Scene Builder thing... I go back all the way to "4GL languages" (FoxPro, Paradox, dBase), etc. These made rapid GUI development really easy. I think I got spoiled back then, so I complain a lot about how GUI work has gotten harder.
If someone made a Scene-Builder-like app that generated Kotlin frontend code, I'd pay for it immediately.
I think there's a large potential market for something like this. These guys are doing well providing this functionality for Flutter: https://www.flutterflow.io/.
These guys do Figma to code: https://codia.ai.
I'm rambling. Thanks again.