Live data from Hacker News

Electron is flash for the desktop (2016)

josephg.com

101–110 of 1001 posts

Re: Electron is flash for the desktop (2016)

#101

Here's the thing. You know what the alternative to all of these Electron apps coming out is? If your answer is "A native Cocoa/WPF app", you are on another planet, the answer is, "It wouldn't exist at all". Nobody in the last 5-10 years cared about writing Desktop apps before Electron came along, there's basically zero money in it, and it's massively expensive, both in terms of actual dev time per feature (easily 10x…

[deleted]

Re: Electron is flash for the desktop (2016)

#102

Here's the thing. You know what the alternative to all of these Electron apps coming out is? If your answer is "A native Cocoa/WPF app", you are on another planet, the answer is, "It wouldn't exist at all". Nobody in the last 5-10 years cared about writing Desktop apps before Electron came along, there's basically zero money in it, and it's massively expensive, both in terms of actual dev time per feature (easily 10x…

> Nobody cared about writing Desktop apps before Electron came along, there's basically zero money in it

I would acutally pay Spotify extra money if they brought back the old, snappy, pre-Electron version of their Windows desktop app.

They replaced it with something that is simply too heavy to manage larger playlists (except maybe on the max-spec MBPs it's being coded on) just because they could iterate more quickly on some non-essential features which they might have packed inside a WebView, leaving essential features intact and responsive.

Re: Electron is flash for the desktop (2016)

#103

> If you want to use JS and react to make a native app, try react native instead. Given the discussion of the recent ReactXP thread, I'm guessing most people don't realize you can do this today . React Native supports macOS [1] and UWP [2]. Edit: There's even some early work on Ubuntu support [3]. [1] https://github.com/ptmt/react-native-macos [2] https://github.com/Microsoft/react-native-windows [3] https://github.c…

I'm probably in that camp too, I thought it was just for android and iOS still (even though I consider myself to keep up to date with these types of things). Do you know if they have anything for linux yet?

I originally thought React Native was for all platforms, then I read their website and docs which made me realize it was only for mobile. That all went down a few weeks ago. Now, today, I find out I had it right the first time. How big a shortcoming is it of their website that it made me go away thinking it was something it wasn't when I had the right thing in mind?

Re: Electron is flash for the desktop (2016)

#104
post #62
post #18

A lot of Slack's high (background) CPU usage is caused by GIFs, in my experience. Just did a quick check on my quadcore MBP, having Slack fullscreen out-of-view with nothing animated in view gives it a CPU usage of 0,1% with spikes up to 2,5%. Switch to a conversation with a single animated party parrot emoji, go to another fullscreen app once again, and CPU usage never drops below a whopping 22%. For an animated par…

Post author here. I thought about that, but there weren't any visible animations playing when I took those measurements. And the 5% figure survived a restart of the client. Its possible there were gifs playing above-the-fold somewhere and reloading themselves, but if so I'd say thats a bug somewhere in the interaction between the 15-20M lines of code in slack, electron and chrome. Its also worth noting that blog post…

Comparing CPU usage % across machines (or even runs on the same machine) without know the p-state doesn't make for a good comparison. This is especially true if you're on a fairly new processor with wide frequency operation range, 5% @ 1.3Ghz != 5% @ 3.5Ghz

Re: Electron is flash for the desktop (2016)

#105

FWIW, we're working on https://github.com/nidium/Nidium presicely to fix this. A new kind of browser engine, not based on any existing engine, allowing developers to use a subset of the web (webgl, 2d, layout) without being forced to use a bloated ecosystem (and which also works on mobile and low end device). Previous HN discussion : https://news.ycombinator.com/item?id=6314961

So another rendering engine to deal with inconsistencies?

Re: Electron is flash for the desktop (2016)

#106

Here's the thing. You know what the alternative to all of these Electron apps coming out is? If your answer is "A native Cocoa/WPF app", you are on another planet, the answer is, "It wouldn't exist at all". Nobody in the last 5-10 years cared about writing Desktop apps before Electron came along, there's basically zero money in it, and it's massively expensive, both in terms of actual dev time per feature (easily 10x…

Completely agree. I simply have no interest in learning any native desktop programming and if I did it would be for my platform only and I wouldn't waste my time writing it for linux and definitely not for windows. I'd release what I had on github and move on. Now I can throw together a small (small by custom code sizes, I know electron is heavy) amount of code and get a cross platform app that doesn't look terrible in relatively short time. I think it's a great first step for a PoC. If it gains enough interest AND (<- big and) you NEED to go native for some reason you can go native later. There are a lot of things you can say bad about electron, yes it's heavy and "bloated" for most uses of it, but if people think empowering others to build things they couldn't or wouldn't before is bad because of how they built it then they are already a lost cause and probably think we should all be writing assembly still.

Re: Electron is flash for the desktop (2016)

#107

Here's the thing. You know what the alternative to all of these Electron apps coming out is? If your answer is "A native Cocoa/WPF app", you are on another planet, the answer is, "It wouldn't exist at all". Nobody in the last 5-10 years cared about writing Desktop apps before Electron came along, there's basically zero money in it, and it's massively expensive, both in terms of actual dev time per feature (easily 10x…

[deleted]

Re: Electron is flash for the desktop (2016)

#108

Why would a tech company not build its flagship product natively on the platforms where it runs? It seems like a generation drift: an obliviousness to the world outside of JS/web dev, and a general disregard for application performance.

because they don't need to. Our phones and computers aren't where they were 10~15 years ago. The end user doesn't even notice if an app is native or running in Electron. Given that constraint, time to market becomes crucial as the huge cross platform barrier is significantly reduced by Electron. It's also a demographic shift. Young developer's aren't coding in Java peak world anymore. We haven't even reached peak Jav…

Definitely a demographic shift. And maybe business smart: cheaper to hire and onboard web devs etc. But that doesn't mean the company and its product shouldn't be critiqued for its architecture (even more so because it is a software company).

Re: Electron is flash for the desktop (2016)

#109
post #61

Telegram Desktop is very good example of modern desktop client done in the most efficient way. C++ and qt, nothing else. Works like a charm an all major operating systems. Easy to install, use and update. Great stuff.

How do they manage to get the very native feel to the UI on Telegram for MacOS? Or is that a different native client? Also curious… in what language and UI framework is their iOS client written?

QT uses native macOS APIs & components in many cases.

https://doc.qt.io/qt-5/osx-issues.html

Re: Electron is flash for the desktop (2016)

#110
post #35

I've been working on a hobby app for some years that is a modern refresh of an old idea. As the article exhorts (and just for funsies, it's just a hobby) I'm writing it using native code and to be conservative on resources. Every place I need to render text or make a thing respond to a mouse click I need to manually do all my own text layout and event handling and so on. (The app is in a domain where it needs special…

If it can't use Qt then it's also probable it can't use Electron, otherwise, why don't you just use Qt?
Post reply on HN