Thank you for the clarification.
I assumed that it could be used for the Web since it had a Web rendering engine,
and could support JavaScript and CSS. It's not the case after all.
JavaFX has a WebView component that uses Webkit to render HTML. Here HTML5 / CSS / JS can be used. By using this component you can integrate a web view or web application in your JavaFX application. Some companies use this to show the help of an application, for example. In this case the help is a HTML page that is styled by CSS. The help can simply be displayed in a JavaFX application by using the WebView component. In addition JavaFX can call JS function in the WebView and JS that is running in the WebView can call JavaFX.