Live data from Hacker News

Electron is flash for the desktop (2016)

josephg.com

11–20 of 1001 posts

Re: Electron is flash for the desktop (2016)

#13
If you like Node.js and HTML/CSS, just have a node daemon running in the background with an HTTP server to your app! It's just like Electron, but without the CPU/RAM/Battery usage. You can even have binaries that stay open after a double-click and automatically open your browser to localhost:40023 (or whatever).

Re: Electron is flash for the desktop (2016)

#14
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

Re: Electron is flash for the desktop (2016)

#16
> 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.com/CanonicalLtd/react-native/blob/ubuntu/REA...

Re: Electron is flash for the desktop (2016)

#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 parrot cartoon.

I'm not sure if this is a bug in Slack or Electron. Doing the same in Chrome does not cause any issues, as GIFs seem to be suspended when the window is not in view. CPU usage goes down to almost 0 when you switch away from your GIF-filled Chrome window. For Slack, however, it barely changes. A big shame.

(On that note, I wonder how much power is wasted by party parrots via CPU usage. Where I work at least one is almost permanently visible in any conversation as a reaction emoji, so it's probably not insignificant.)

Re: Electron is flash for the desktop (2016)

#19
Very timely article. But I have been told to shut up and use Atom/VSCode/Slack like everyone else and upgrade hardware if software runs slow.

I find memory/cpu efficient applications not just useful but respectful to users specially when upgrading hardware is not possible due to financial or policy reasons.

Re: Electron is flash for the desktop (2016)

#20
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…

I want to say that VS Code had the same issue because of the blinking cursor, which was controlled by a CSS property to toggle.
Post reply on HN