[フレーム]
BT

InfoQ Software Architects' Newsletter

A monthly overview of things you need to know as an architect or aspiring architect.

View an example

We protect your privacy.

Facilitating the Spread of Knowledge and Innovation in Professional Software Development

Write for InfoQ

Unlock the full InfoQ experience

Unlock the full InfoQ experience by logging in! Stay updated with your favorite authors and topics, engage with content, and download exclusive resources.

Log In
or

Don't have an InfoQ account?

Register
  • Stay updated on topics and peers that matter to youReceive instant alerts on the latest insights and trends.
  • Quickly access free resources for continuous learningMinibooks, videos with transcripts, and training materials.
  • Save articles and read at anytimeBookmark articles to read whenever youre ready.

Topics

Choose your language

InfoQ Homepage News JavaFX: One Codebase for Web, PC, and Mobile

JavaFX: One Codebase for Web, PC, and Mobile

This item in japanese

Lire ce contenu en français

Jul 12, 2021 1 min read

Write for InfoQ

Feed your curiosity. Help 550k+ global
senior developers
each month stay ahead.
Get in touch

Gluon has published a status update for JavaFX, showing the way in which a single JavaFX codebase can be used across a PC (standard JavaFX), a mobile device with Android or iOS (through integrated GraalVM), and a beta of browser-based WebGL (through Gluon).

The new addition of WebGL expands the level of support into the browser client side, enabling developers to write the entire application in a single Java language or codebase, without requiring a specialized JavaScript frontend. The change can benefit developers who write client applications used across multiple device profiles or those who create web frontends that are hosted on web or packaged locally through techniques like Electron.

Pi4J contributor Frank Delporte published a guide and sample project designed to showcase the capability to deliver a single application across Mac and Raspberry Pi devices like the Elecrow CrowPi2 laptop. The project demonstrates how to use common libraries and stylesheets like ControlsFX and BootstrapFX to make JavaFX applications look similar to what users expect. This change can speed up development by using common shared components while retaining a familiar sense of style that applications simply "look different" than what users are used to.

Gluon’s approach delivers a fully client-side component that does not require anything on the server. When built, the JavaFX code is transpiled to JavaScript and then invokes WebGL code. This approach makes JavaFX web frontends accessible to serverless applications because no persistent server-side state is required.

While JavaFX provides the groundwork for cross-platform applications, usage is low across the industry with JavaScript/Web clients far more common. StackOverflow trends reports on similar cross-platform development trends show a relative rise of Flutter and React-native while JavaFX is largely unchanged. When compared against direct numbers, JavaFX has 120,000 students on Udemy compared to React-Native at 900,000 and Flutter at 1,500,000.

JavaFX was recently discussed on the Foojay podcast, with members indicating that the best approach for cross-platform applications is to select a common application style rather than to emulate each platform’s native environment. Developer Gerrit Grunwald pointed out that iOS controls are highly unique with state information commonly outside of the Object represented by the FX control.

Rate this Article

Adoption
Style

This content is in the Java topic

Related Topics:

Related Content

The InfoQ Newsletter

A round-up of last week’s content on InfoQ sent out every Tuesday. Join a community of over 250,000 senior developers. View an example

We protect your privacy.

BT

AltStyle によって変換されたページ (->オリジナル) /