Live data from Hacker News

Electron is flash for the desktop (2016)

josephg.com

571–580 of 1001 posts

Re: Electron is flash for the desktop (2016)

#571

Earlier quoted context omitted.

> Electron applications are shite in comparison with proper native applications. They fail to integrate with the host platform, they are slow, they hog memory and drink power. Are they though? The two applications that use the most energy on my Mac - by far - are Steam and Skype. Steam still has trouble with HiDPI and freezes when performing various UI interactions. The number of problems with Skype are uncountable.…

You need to compare apples to apples: The right benchmark for VSCode is not Visual Studio, but Notepad++ (5.9MB on my system right now).

The right benchmark for notepad++ is not visual studio. It's notepad2.

Notepad2 = 1792 kB.

P.S. Pay attention, this is kilobytes, not bytes :D

Re: Electron is flash for the desktop (2016)

#572

People complaining about electron are the same type than the ones that used to say : - why are people writing this stuff in C. It's so slow and you don't have as much control on memory. Write it in Assembly. - why are people writing this stuff in Java. It's so slow and you don't have as much control on memory. Write it in C. - why are people writing this stuff in Python. It's so slow and you don't have as much contro…

> why are people writing this stuff in C. It's so slow and you don't have as much control on memory. Write it in Assembly. did anyone ever actually say this? > why are people writing this stuff in Python. It's so slow and you don't have as much control on memory. Write it in Java. this one is odd to me considering Python came first...

That was a common refrain through the 90s and early 2000s – compilers, and especially open-source ones, have improved significantly since then but at the time it was relatively common for someone to replace a hotspot with inline assembly for a significant boost.

Re: Electron is flash for the desktop (2016)

#573
post #158

Earlier quoted context omitted.

> I simply have no interest in learning any native > […] programming And it is amazing to see how many bad reinventions of the wheel happens because of this. People claiming that writing electron app is 10x faster than native have absolutely no idea what they are talking about. The only think web-based tech will give you is ability to push out raw cross-platform prototype. Now try to polish that to the acceptable qua…

I am a web developer, I know that might be a dirty title in some circle but I really don't care. There are countless amazing things built on technology that people hate for whatever reason. PHP, JavaScript, and even Flash comes to mind. Guess what wins in the end? The thing that gets the job done quickest and easiest. It's one thing I really dislike about HN, the need to let everyone else know how terrible their deci…

> Real programmers design and build their own FPGA's for their code...

https://xkcd.com/378/

/I don't disagree with you one bit...

Re: Electron is flash for the desktop (2016)

#574
post #113

Earlier quoted context omitted.

> They fail to integrate with the host platform Just as a counter-point, because native app fans often make this point as though it is universally recognized to be a good thing. I don't want apps to integrate with the host platform. The host platform is not the thing I care about. I use several host platforms in different contexts (I have work and home computers and a smartphone, they all run different OSes) and I wo…

I doubt you don't care. These are examples "integration with the host platform": * Text selection * Caret behaviour (e.g. Option-arrows on macOS) * Clipboard * Spell check * Open/save dialogs * File system access * Drag/drop * Window management * Accessibility (screen reader support etc.) * Standard right click menus * Indexing (e.g. Spotlight on macOS) * etc. You may be thinking to native UI idioms, which even Apple…

Google doc is a lost fight. Word and spreadsheet editors need to be proper desktop web applications.

A web site inside a browser cannot resemble that and all the hacks to try to are not getting much close.

Re: Electron is flash for the desktop (2016)

#575

Earlier quoted context omitted.

Yeah, but Python still doesn't seem to have a great cross-platform desktop GUI, as far as I can find. I'd prefer to code entirely in Python if I could, but I haven't liked a single GUI library I've tried for Python. Although to be fair I haven't really tried PyQT out still, but I don't like the idea of having to buy a commercial license for it.

PyQT is alright. Kivy as well. Or anything in any other language. But none of them are close enough to the benefit of being able to use the tone of experience from the Web UI into the desktop. Eventually all GUI app toolkit ends up with a custom MVC framework, a client/server architecture, some kind of db for persistence, their own implementation of asynchronous event and communication models and a declarative layer…

Yep, completely agree with everything you said. I'd love for their to be a standard on the desktop side, but until then, I'll keep using a hodge-podge of technologies depending on the project, I guess.

Re: Electron is flash for the desktop (2016)

#576
post #456
post #344

Earlier quoted context omitted.

> much slimmer Yeah... I opened a 500KB log file in vim and Notepad++ and they are using 5 MB and 7 MB of RAM, respectively. They both also manage to use no measurable amount of CPU (even to blink the cursor!) unless you interact with the window.

But - can I get a copy of Notepad++ on my Linux box? No? Now - I know there are a ton of other options for Linux, but the thing is, I can't jump from system to system and have the same app with the same experience - even if the app was developed as a native app for all of the platforms, because each has a slightly different native GUI implementation and usage which doesn't translate fully between each. So now I have…

> But - can I get a copy of Notepad++ on my Linux box?

Yes.

Re: Electron is flash for the desktop (2016)

#577
post #477

Earlier quoted context omitted.

We use Java because Python proved to be too slow.

Java also has JavaFX, which comes with an embedded Webkit browser. I can create my UI with React, or any other HTML/CSS/JS library, and make it interact with code written in Java, Scala, Groovy, Clojure, Kotlin, Ceylon, Frege, etc. very easily. I think this provides all the benefits of Electron, but is even more flexible and powerful.

add nashorn so you have a spare javascript vm just in case...

Re: Electron is flash for the desktop (2016)

#578

Earlier quoted context omitted.

We see the same thing with containers. Docker, flatpak, snap... It's just the right time for it. Languages have evolve to change the way we handle constraints like memory, speed, readability, expressivity etc. We are arriving at the pick of what languages can bring on the table. Sure we can improve things here and there, but the huge challenges now are integration, packaging, distribution, updates, communications, mu…

I agree. Containers should be unnecessary -- all that they could provide could be done at the process level with an operating system designed to isolate computing resources appropriately. But operating systems were not historically designed for that so another (somewhat ridiculous) layer is added on top.

Thats all containers are?

They are an abstraction over OS level isolation.

Re: Electron is flash for the desktop (2016)

#579

Earlier quoted context omitted.

That's nonsense . Desktop apps have been frequently released since forever. The underlying issue here is that Electron reduces the barrier to entry for cross-platform development . That is, it's cheaper to build a single cross-platform application in Electron than it is to build two or three native applications, and you can re-use your existing web experience. I can completely understand why companies might choose th…

> ... Electron applications are shite in comparison with proper native applications. Is that true from a user's perspective? The average user I know would not have the idea that Slack is somehow inherently worse than say MS Word or any other truly native app they use everyday. What would Slack gain by integrating better with my Mac? Slack starts up too fast for me to read the little quotation (penultimate Macbook Pro…

I actively don't use and discourage people from using Slack where I can because of how poorly it runs.

Re: Electron is flash for the desktop (2016)

#580

There's two kinds of developers. Dorks who care about programming, and programmers who care about creating deliverable value. What do consumers think about electron apps? That's all that matters. Consumers don't know what the heck electron is, only that their apps work seamlessly across platforms. The only people who complain about electron apps are dorks who have an axe to grind with web developers. I'd rather have…

I'd like to suggest an edit to two kinds of programmers: There are programmers that care about the quality, elegance, and beauty of their code, and there are programmers who just want to make the most people happy as fast as possible. Fine dining vs fast food.

There's a difference between writing maintainable code and premature optimization. Experience is knowing the difference between you can and you should.
Post reply on HN