Hacker News new | ask | show | jobs
by Polarity 2629 days ago
What´s the problem with this? I have enough space on my drive. Sure the app is bigger but it´s platform independent and works flawlessly. Native apps crash often, use big os dependent frameworks (you have to install sometimes) and only to have a smaller bundle? I don't get it.
4 comments

> What´s the problem with this?

The problem? When you start to have 5-6 apps running with Electron in the backend and start to take 10% of your CPU time and 2 Gigs of RAM, you will start to feel how it impacts your working environment, battery life and all.

Just download more RAM!

On a serious note: I never understood why people tell me to buy better hardware to compensate for the shitty performance of their software. No, fix your software!

Because there are few people on earth more entitled than the modern web developer?
Nah dude this line of thinking got us here. We need to reach back to what the OG's in computing thought about. Small size, fast performance. Limit ourselves.

I read about this dude who purposely writes software on a shitheap laptop just so that "if it's fast here, it's fast on modern mobile phones."

Even my app written in Elixir and uses 160MB of RAM after letting it run for a week; I've been thinking: "Maybe I could bring it lower to what nzbget uses (around 59MB)". I've been exploring Nim for that.

We need a return to small-footprint as a feature.

Hehe, kinda funny when an application comes with more security vulnerabilities than it has lines of code for its own logic ;-)

EDIT: edited to make it less ambiguous

My app does very little and is meant to be self-hosted for your own use. Or are you talking about Elixir or Nim as a language?

Edit: Oh I get it you actually meant:

"Hehe, kinda funny when your application written for Electron comes with more security vulnerabilities than it has lines of code for its own logic ;-)"

Sorry, is this a comment on elixer or Nim?
Neither.

It is about having a color picker (probably just a few lines of code) bundled with quite a set of dependencies and complex chromium runtime environment which does not get updated regularly. Therefore they keep their vulnerabilities even after they are known and fixed in later versions of the dependencies.

With small footprint applications, you are less likely to have such problems.

Can't argue with you there, I tend to use tcl/tk for something this small.
There is no problem. It is just like flying with a helicopter to the supermarket. You just need a supermarket with a large enough parking lot.
but better than using 5 different cars for 5 different supermarkets.
First, this is a false dichotomy. There are alternatives to Electron that don't require a 120 MiB runtime and don't involve using the OS APIs directly.

Second, this is not a criticism on application writers, but on Electron itself. It could use a runtime available on computers (virtually every computer has a browser) or, at least, a shared runtime that would download itself.

Bundling a browser with EVERY different app is not only a waste of space and of RAM, but also a security issue: now you have to wait for each app developer to update the app in case there's a security problem with Electron, Chromium or any of its 2000 dependencies, and that's "if" they upgrade. And that update takes at least another 120 MiB to download, for each Electron app you have.

Instead of downloading 120 MiB for each app, each app could come in a small package and only download the runtime if it's not available in the computer yet. Java got it right in the 90s, .NET got it right in the 2000s, although downloading the runtime had terrible UX for stupid marketing reasons (you had to provide e-mail to download from the Sun or the MS website).

> What´s the problem with this?

It's 120 MB for literally a fucking color picker.

yes and it works everywhere, everytime.
Every native app I've used works everywhere I've used it, every time as well.

That native apps were wildly unstable, or that it was impossible to find native apps that ran on different platforms before Electron is a myth. Electron didn't solve those problems, because they weren't problems.

Electron solved the problem of "how can I, a web developer, run a website on the desktop but make it seem like a native app and call myself an application developer?"