I never “got” electron. My work is building webapps and I don’t see why anyone would want to use HTML and JavaScript to develop a significant desktop app with modern UI.
I can only assume web technologies and electron got popular because all of the Desktop platforms where trying to jump to tablets and phones and whatever else they considered new and shiny so that while web tech was a terrible stack it was at least stable.
P.S.: I sort of hope for Griffon to make a come back. Griffon framework + Groovy + JavaFX looked nice to me.
> while web tech was a terrible stack it was at least stable.
No no no. Web tech was/is terrible, but it's dirt cheap. You can hire JS hacks by the boatload, and retrofit whatever they build into an electron app relatively easily. Whereas desktop developers are few and expensive, and they tend to optimise for this or that platform or toolkit.
Electron didn't win on quality or features - it won on the back of commercial realities of the development world.
I don't think 'desktop' devs are any more expensive or cheaper. There's definitely way less of them and majority of people who know stuff like Win32 APIs are either very specialized or working on games.
That's what a lot of companies did 10-15 years ago in Poland. Sometimes it was Delphi. Of course, the applications were shitty, but also a lot of web is shitty.
As a layout and rendering toolkit, the modern web browser is just head and shoulders above everything else in terms of features and ease of use.
As problematic as CSS is, getting things in the right place is still dramatically easier than with Swing LayoutManagers, and when you do have problems, you have great tools in the browser to explain what's going on.
Browsers particularly shine in text rendering, naturally; text styling, font selection, word wrapping, etc. are all easily configurable. You want bold text next to regular text in Swing? You either need two JLabels, or you wrap your text in <html> tags and let the embedded HTML 3.2 renderer do it.
Whaaat, no way. Sure, Swing is not the epitome of a framework, but the web was famously terrible before flexbox, and it is still not as advanced as something like Apple’s constraints based layouting system.
Also, word wrapping? HTML is quite terrible to read compared to Latex-rendered text so I wouldn’t say that it is all that good in fonts either.
Swing isn't exactly the latest toolkit though, is it?
JavaFX has much more intuitive layout for apps than HTML and also has CSS. So you can get the best of all worlds. HTML5 has been trying to catch up with CSS flex-box, but it's all just retrofitted and shows.
Well, there are a number of “selling points” to electron/NW.JS or similar: reuse JS code/skills/libraries (npm) to build desktop apps; use Node.JS to build desktop apps; cross-platform. It clearly lowered the barrier and from a company’s perspective front-end talent’s “reach” is expanded.
Even way before they came out I wondered why more native apps didn’t just reuse HTML/CSS at least (many did).
Of course we all know of the downsides of Electron (basically Chromium + An App in every app; ridiculously heavy-weight.
I’m fond of the webview project and Tauri, being built on top of it. It reuses the available system browser view and doesn’t bundle Node, so it’s very light.
> It reuses the available system browser view and doesn’t bundle Node, so it’s very light.
It's 'light' in terms of download size, it's not far off from Electron in terms of resource usage. Most complaints about Electron are about resource usage, not really download size (though there are some).
I can only assume web technologies and electron got popular because all of the Desktop platforms where trying to jump to tablets and phones and whatever else they considered new and shiny so that while web tech was a terrible stack it was at least stable.
P.S.: I sort of hope for Griffon to make a come back. Griffon framework + Groovy + JavaFX looked nice to me.