r/JavaFX • u/Draaksward_89 • Jan 13 '25
Help JavaFX plus Spring Boot 2
Could someone please forward me to a working doc/example/tutorial for adding JavaFX (openjfx or smt) to an existing SpringBoot 2 project?
1
Upvotes
View all comments
Show parent comment
1
u/Draaksward_89 Jan 14 '25
Thanks. I'm basically stuck on the part of making a JavaFX app. I have used it before, but in an era of Java 1.6 when it still came with JDK.
I remember it worked well with just starting the main class with, if I remember correctly, starting Spring's context (or was it the other way around), but that project was I think 6 years ago (not a new to java, just can't find a relevant doc/tutorial to make JavaFX running).
I am basically stuck on the step of executing even the simplest hello world with JavaFX, with some tutorials state to add VM options when there's everything in pom (I am more used to Maven, but yes, I do know the benefits of Gradle, just more used to Maven). Starting from a class (I later realized that module-info was used in the openfx archetype, which I never used tbh) resulted into a series of
I did manage to run through `javafx:run`, but I remember making it work right from the class (I do plan to package it into an executable, but for now I want to set it up without compromises (I do see javafx:run as a workaround, suggesting that I'm doing something wrong).
So I gave up and posted this question, hoping that people, who use JavaFX more frequently than I, to point me to a working tutorial.