Live data from Hacker News

Electron 7.0

electronjs.org

211–220 of 289 posts

Re: Electron 7.0

#211
post #44

Hey, another electron thread. Wait a second, did someone already mention how horrible Javascript is? The memory consumption? The minimal integration into the OS/desktop (think accessibility)? Hmm ok, I need something new... Here it comes: chrome is inherently instable. The Google developers give a shit about their dependency management and have trillions of open source projects just literally copied into their trunk.…

Haha found the Java programmer, wake up guy. It's the 21st century.

Re: Electron 7.0

#212

Earlier quoted context omitted.

> My understanding is that Electron is for JavaScript what Qt is for C++. This is a weird comparison. Electron isn't really a UI framework, it's more of a customized web browser and JS runner, with some platform APIs to bridge the gap. But no, I don't know of anything serious that lets you write web UIs in C++. The closest you'll get are things like Google's Closure Compiler which compile Java to JS. There's very lik…

Closure compiles JS to JS, you must be thinking fo GWT.

Right.

Re: Electron 7.0

#213

Earlier quoted context omitted.

I release two apps, across 3 OSes, in somewhat of a bimonthly cadence with a low defect rate. That’s 6 different binaries. I’m a solo founder. I know people like to rag on Electron, but without it, I wouldn’t be using something else, my apps just wouldn’t exist . It allows more people to try building more thing and that is a net positive. The speed problems and bloat issues of Electron is just shoddy programming on t…

> I release two apps, across 3 OSes, in somewhat of a bimonthly cadence with a low defect rate. That’s 6 different binaries. I’m a solo founder. I release a Qt app for mac / windows / linux whenever I want by tagging a git commit and letting it be built by CI services. There is a single code base with almost zero platform-specific code. I really don't think that the technology choice is what matters in this.

As someone who has worked a lot with both Qt and React at my current job, I feel that React is significantly easier for almost everyone. Qt’s complexity negates a lot of its benefits in most hands.

Re: Electron 7.0

#214

Earlier quoted context omitted.

>The speed problems and bloat issues of Electron is just shoddy programming on the maker’s part - Electron itself isn’t slow. I doubt this is entirely true. VSCode is frequently cited as an example of a good, performant Electron application. Its performance is generally acceptable (I use it as my primary text editor), but it absolutely chugs sometimes. Sublime is light-years ahead in terms of performance.

That is true and as a user of Sublime myself, I agree. However, VSCode is still a JS app that has to do its computation on a single thread, on a largely interpreted language. If you do it the way I do and use Electron as a skin / thin client to a compiled binary within the package, you remove that bottleneck. That way, you get both cross-OS capabilities, a familiar UI toolkit (JavaScript, I use Vue) and native binary…

JS doesn’t have to do computation on a single language. Web workers an option, and I believe Node has additional tools as well.

It definitely can’t compete with true threads for work that needs true threads, but you probably don’t have much work that needs true threads (rather than just workers and channels).

Re: Electron 7.0

#215

I'm bullish on Electron. I think it's just a couple of technical advancements away from being the ultimate desktop toolkit. For context, I love and have worked a ton with Qt, and I much prefer Qt UIs as a user. But Electron has brought true cross-platform development to all platforms (Including Linux!). If it weren't for Electron, I wouldn't even have a bunch of the apps I use today. Hell, I wouldn't have a good IDE,…

Electron is so heavy you could include a copy of Windows 95 with every application and use its GUI. This is how ludicrous the state of modern computing is. Java accomplished the same thing with fewer limitations and vastly more efficiency. Best case scenario of the continuing "evolution" of electron is the elimination of the OS entirely. Why do you need it? Just put drivers in Chrome and be done with it. It's already…

Java eats about a quarter-gig of disk space on my windows installation. That's a bit less than the base electron bundle. That is one installation for the computer, but that's due to dumb packaging (you _could_ just tell everyone to install chrome, just like you used to tell everyone to install java; we've forsaken that space for convenience.) The ui of java then was significantly more bounded in flexibility. So we've forsaken space savings of old java for subjectively-prettier ui.

> Best case scenario of the continuing "evolution" of electron is the elimination of the OS entirely. Why do you need it? Just put drivers in Chrome and be done with it.

Have you used a chromebook?

Re: Electron 7.0

#216

Earlier quoted context omitted.

Electron is so heavy you could include a copy of Windows 95 with every application and use its GUI. This is how ludicrous the state of modern computing is. Java accomplished the same thing with fewer limitations and vastly more efficiency. Best case scenario of the continuing "evolution" of electron is the elimination of the OS entirely. Why do you need it? Just put drivers in Chrome and be done with it. It's already…

> Electron is so heavy Does it matter? I think heaviness should be defined relatively to the computer resources. Currently VSCode memory usage is 75MB on my computer. It could be 10 times less, it wouldn't make any difference.

Which OS are you using for that kind of memory usage? I've tried it, and seen double that out-of-the-box.

Re: Electron 7.0

#217

I'm bullish on Electron. I think it's just a couple of technical advancements away from being the ultimate desktop toolkit. For context, I love and have worked a ton with Qt, and I much prefer Qt UIs as a user. But Electron has brought true cross-platform development to all platforms (Including Linux!). If it weren't for Electron, I wouldn't even have a bunch of the apps I use today. Hell, I wouldn't have a good IDE,…

If only each OS would ship an abstraction layer that guaranteed "at least modern browser X" that one could ship into. I want to ship an electron app but I want it to be 100kb and start in 0.1s and take almost no memory because the libs are shared. I don't want each little chat app or music player to gobble up half a gig of ram and take 3 seconds to start.

You just re-invented the PWA, basically. Only modern browsers support them (though you can't guarantee eveyrone has one), so you just package and ship a web site. Of course, browser tabs themselves can take a lot of memory; a fair number take 50 megs apiece, and some take 100, so don't bet on your site necessarily only taking a few kb.

Re: Electron 7.0

#218

Earlier quoted context omitted.

I don't. The reason is UI kits on different OSs are so different that allowing this stuff makes for haggard looking apps. Using the web at least brings consistency to the experience. There's no workaround I can think of, you either write one UI per OS (even with QT you still need to adjust for conventions, spacing etc...) or you make an OS agnostic UI with Web tech.

> (even with QT you still need to adjust for conventions, spacing etc...) That is what I'm talking about: SwiftUI automatically uses the recommended conventions for spacing, padding, etc. which are different for macOS vs. iOS etc., and it also takes user environment settings into account, like font sizes and other accessibility options.

It can do this only because Apple exercises such tight control over all platforms. When everything is developed under the same roof, it is significantly easier to make it, "Just work." On the other hand, making three, independently-developed platforms look the same is nearly impossible. On a windows or linux box, you cannot guarantee things like screen resolution, ppi, dimensions, specs, compatibility, and the innumerable other things that cause trouble.

Re: Electron 7.0

#220

Earlier quoted context omitted.

> Because it does effect me. [..] VS Code? Definitely not my first choice, but its rust support is still better than IntelliJ So choose an Electron supported OS or add OpenBSD support to Electron somehow. If VS Code is important enough to you, then that's a trade-off you have to make. I don't think I'd agree that Electron is "hacky". I'd certainly say it has shortcomings, but what technology doesn't? Rust certainly d…

So choose an Electron supported OS Why? My whole point is that Electron is encouraging developers to not support other platforms. That's not helped by simply using something that the Electron devs have blessed. The absolute last thing I want is Electron to dictate which platforms I can and cannot use. or add OpenBSD support to Electron somehow. This too seems like a fools errand as the Electron devs have decided that…

> Why? My whole point is that Electron is encouraging developers to not support other platforms.

Because you expressed a need for vscode. If you need it, figure out how to use it. If you don't need it, it's not a problem, right?

> This too seems like a fools errand as the Electron devs have decided that anything beyond Windows, MacOS, and Linux will not ever have official support.

"official support" are the key words there. If you care about it that much, whip up some patches and maintain them. Or even better, find other OpenBSD users to help you build and maintain them. Just because the electron devs don't want to support it doesn't mean it can't happen.

> Then don't. I'm currently working on a project that's using a rust backend and a Qt/QML front end. If you're more comfortable with JS then QML is an easy leap. The caveat being that you've got to drop down to C++ for some things.

JS but C++ for some things is just as bad as C++ for everything. Qt isn't an option for me any more than Electron is an option for you.

> Right, and now we're back to "this sounds good to the devs" while the users suffer.

Users don't actually suffer that much. You appear to be looking at this through the lens of your own environment -- you might suffer because of Electron, but people don't give two shits what slack is built with as long as it works reliably.

> Low effort cross platform toolkits have never yielded particularly good results.

If your web app is good to begin with, bundling it in Electron doesn't make it worse. You seem to be okay with browser based apps, so I'm not understanding where that disconnect is.

> Vi (typically vim) I use for some things (even with rust dev), but I'm not about to replace a full blown IDE with it.

Whatever works. vim was my daily driver for a long time. Works just fine as an IDE. Neovim is better. YMMV.

Post reply on HN