Hacker News new | past | comments | ask | show | jobs | submit login
Electron 1.0 is here (github.com/blog)
679 points by alanfranz on May 11, 2016 | hide | past | favorite | 393 comments



Our team at Nylas has been incredibly lucky to build on the shoulders of the folks at GitHub and I'd just like to thank Kevin, zcbenz, Jessica, and their entire team. They've been awesome to work with and super supportive of this new community.

Our early prototypes of Nylas N1 were built on Angular in the browser, and then Adobe Brackets, but we couldn't really get it to a level that felt great and worked offline. It wasn't until we decided to fork Atom (the previous base of Electron) that we started breaking past the "uncanny valley" of wrapped webviews and discovered an application stack that allowed quick cross-platform deployment alongside native code modules.

After building on Electron/AtomShell for 18 months and seeing the community grow, I can definitely say there is something really special here. We've still got a lot of work to do on N1 (email is hard!) but we're confident Electron is the right platform for this type of extensible app.

A secondary reason we open sourced N1 was to serve as a reference implementation of a large Electron app. There still isn't a great resource for "best practices" when creating complex Electron apps with lots of moving parts. Now that we've hit 1.0, I think it's time to change that!

If you have a free afternoon, I definitely recommend playing around with Electron. It will likely change your outlook on the future of desktop software. :)


Building a larger Electron app myself, thank you SO much for opening up your code. There's a ton to be learned, like you said, about best practices with Electron. I"ve spent so much time shuffling things around and refactoring that I can appreciate a good foundation for consistent file trees.


I'm going a little off-topic here, but i just found out about Nylas. What i don't understand is the Cloud integration. If i use Nylas with my IMAP account, does Nylas upload any data to your cloud?

Can i use it as a basic Mail.app/Thunderbird alternative, without leaking my personal data to your cloud?


Not the OP, but AFAIK, Nylas does store your email in their cloud.

This allows the client to be thin, since it's only using the APIs and is shielded from the intricacies of dealing with mail protocols like IMAP and SMTP. It also allows Nylas to offer a single API that works across all your email.

https://support.nylas.com/hc/en-us/articles/217518207-Why-do...


Thanks!


>It will likely change your outlook on the future of desktop software. :)

Slow, with a 100MB node runtime eating up an entire CPU, piling hacks on hacks on React on top of the DOM, being dependant on Google's will to develop V8, written in JavaScript? That sounds like a pretty damn bleak future to me.


Other than a little startup lag VS Code which runs on top of Electron performs very well on my computers, though they all have SSDs. As to performance and memory footprint vs. a statically compiled language/platform, yes, it's a bit heavier... that said, people are writing useful software with it, and able to deploy it cross platform, with minimal additional effort, and able to re-use components build for web based versions.

It's not ideal for some apps, but it's completely serviceable for most apps.


Oh I'm not contesting the fact that it's serviceable. Our job is to deliver software. I'm just slightly concerned by the absolute disregard for performance and power usage that is implied by using Electron.


A whole 100MB... GASP! Meanwhile native MS Office on osx takes up almost 7GB.


* I meant 100MB memory footprint. Office doesn't have a 7GB footprint.

* Office being a behemoth doesn't give a right to other apps to be whales.

* 100MB is just the runtime. Then you've got your application running on top of that, using whatever memory you want. The C/C++ runtime is not 100MB.

* Those 7GB probably include examples, layouts, whatever. Actual content. As opposed to Electron apps which are rarely more than just pretty interfaces making requests to a server. (With some high profile exceptions, like Atom, VSCode, ... Although they do send data to outside servers anyways :^))

* The Office suite is infinitely more complicated than anything done with Electron. That means features, technical debt, everything.

* Office isn't running in fucking Javascript


Oh really?

* Excel alone uses 86.1MB of private memory, and 142MB on a Blank Workbook.

* Where did you get this 100MB metric? VS Code uses 24MB Private, 86MB shared and I've got a ton of extensions added.

* No, most electron apps are offline apps.

* I doubt it. Creating performant HTML layouts and WebGL rendering all verified by independent 3rd party test suites is hard, dude. If someone came to you and said "Build a HTML engine or build Word" which would you choose?

* O'rly? Office 2016 add ins are built in JS, and there are built-in "addins"


>Excel alone uses 86.1MB of private memory, and 142MB on a Blank Workbook.

That is excel. With all its features. 100MB is Electron's base footprint. Running absolutely nothing. Write something as complex as excel with the same feature set, you're going to be way over 142MB with a blank workbook ;)

The 100MB metric comes from experimentation with both electron and electron based apps (VS Code, Atom, N1, Slack, ...). The main process hovers at around 80MB, but you also have countless node processes running. When node will be a default on machines (please, never), I'll stop adding those processes to the total, but meanwhile, they do count.

>I doubt it. Creating performant HTML layouts and WebGL rendering all verified by independent 3rd party test suites is hard, dude. If someone came to you and said "Build a HTML engine or build Word" which would you choose?

A) The electron developers do not develop a rendering engine. They do not develop a JS VM either. They develop a toolkit for desktop apps, which uses nodejs (which is highly dependent on Google not pulling the plug on V8) as well as Blink (which is highly dependent on Google). While I am not discounting their work, they are absolutely not the ones with their hands in the engine internals.

B) I would honestly build a rendering engine. Word has 25 years of backwards compatibility to keep, features and integrations with lots of other office software, etc. Rendering engines have a clear and defined spec. Microsoft hasn't clearly defined the DOCX spec (well, they did, but keep adding undocumented surprises. Just like XLS :^).

C) I'd ask for a team, because no single human being can replicate the feature set of either in his lifetime.

Add-ins in JS? Sure, run them in an another thread and keep them out of performant code and we'll be friends.


Why the aversion towards JavaScript? It's steadily improving, albeit slowly, with massive support from many players.


Not in the least, it's dynamically-typed with ecosystem libraries removing APIs by the dozen (upgrade your dependencies? prepare for days of verifying runtime errors of missing functions), and TypeScript is still a second-class citizen even despite the increasing amount of TypeScript-first libraries (like Angular2)...


> Office isn't running in fucking Javascript

Yet. ;)



Isn't V8 open source? https://github.com/v8/v8


Well, it still doesn’t feel native on linux.

You get 2 window bars, and 2 toolbars, nested in each other.

http://i.imgur.com/2C769ex.png

It might be "best practices" on Mac, maybe even on Windows, but it definitely looks out of place on Linux. Especially when compared to native Qt apps.


Maybe, open an issue? It is still a work in progress after all. Lot's of open issues for Linux so far. [1]

[1] https://github.com/nylas/N1/issues?utf8=%E2%9C%93&q=is%3Aiss...


I had 4 open issues about several topics, all closed as "not enough people affected" or "WONTFIX".


Yeah. It looks as iPhone's icons on an Android phone. These could be high quality made but surely out of place.

Maybe detect the platform and use native icon packs when available?

Anyways it's amazing how good Linux have become that we could complain of such minor things ;)


In comparison to most GUI apps on Linux, this looks pretty good. It might not be perfect, but if i had to choose between no linux port, and a good-enough linux port, i'll choose the latter.


It looks "good", but not, as claimed by the Nylas team, "native".

Even Swing and JavaFX manage to make better looking, faster running, easier to code UI apps, which can be distributed smaller (the Java Runtime, thanks to Jigsaw, is smaller than the node+Chrome runtime of electron)


There isn't really a standard native look to Linux, as we have so many desktop options and related toolkits.


The problem with asking for a GNU/Linux standard application is there are several toolkits for developing them that stand out when not in the same base as the desktop environment. There is a single concise appearance to certain distros (e.g. Elementary), then difference of appearance in desktop environments (e.g. GNOME, KDE) and then there are the toolkits that are written completely different and use separate libraries (e.g. Qt, GTK).

By asking for a "Linux native application", you would need to create forks for GTK/Qt theming at the minimum and change the appearance altogether. It's just an absurd request really. One thing Electron does not do well is per-system graphical elements. It renders the same on every system so you either have a unique application design or you're conforming more to Window, Mac, or GNU/Linux. Or doom yourself to an old stale design, which is bland enough to fit in every category, but isn't the aim of the project.


You realize that GTK and Qt are both compatible with the other?

Most GTK apps work nicely under Qt (although this is very suboptimal), but especially Qt apps look native everywhere. From windows to mac to KDE-environments to Gtk-environments.


What do you mean by gtk under Qt? What about Tk apps, or Athena apps, or Motif, or GNUStep, etc.? There really is no such thing as a native Linux look and feel, you just happen to use a consistent selection of apps on your own system.


What I mean is that a Qt app will look native everywhere, and Gtk apps will look native in most places.

Most other toolkits, as you mentioned, don’t look native in many places, but Qt natively supports the CDE style, the Motif style, all different Windows and Mac styles, etc.

A Qt app looks native on Mac OSX, on Solaris, under Gnome, under KDE, under Windows XP, under Windows 10.

That’s why I avoid apps that aren’t either native or Qt anywhere, no matter if I am running Gnome or Windows, KDE or Mac.


Can you point me at an example of an app that does it really well? We couldn't find any compelling ones when we were investigating platforms for N1. :/


There basically is. Linux per se is just not a desktop OS, like Windows or OS X. Ubuntu has a standard UI, Debian's default install has a standard UI, Kubuntu has a standard UI, and so on.


That's even worse though. You can't ask for a universal GNU/Linux native appearance since there are Debian/Kubuntu/Ubuntu standards for UI. The list goes on and on too.


It feels like a web app, and I guess that's what it is in a sense. I've noticed that Electron apps don't also go with system-wide GUI themes.

Incidentally, nice looking desktop! Which distribution is that, if I may ask?


That’s the KDE Plasma Desktop – I am running it on ARCH Linux, but the new Kubuntu (which I have on my laptop, and looks exactly the same) http://www.kubuntu.org/ has the same desktop.

The wallpaper is from http://imgur.com/gallery/dbELn


Electron saved my ass when I was trying to come up with a simple solution for non-technical people trying to get their things done. So, thank you and team for doing this. I would like to see this achieve what Java couldn't.


I'm curious, and not willing to fill out a form to find out... it looks like N1 uses Nylas Cloud for data/services... that said, there's no actual published cost for this. I have several email accounts and would love a cloud/web version to access them all, combined with a standalone (desktop-ish) app, as the electron one... But I'm concerned about the pricing model, and with no openly published price, and no apparent income source, I am hesitant to even try the application.

Thanks for the work you are doing here, I feel that Email is one area that could use a lot of work.


It's here: https://nylas.com/pricing

And you can read our blog post about announcing the pricing: https://nylas.com/blog/nylas-pro/

We haven't yet shipped the version which allows you to upgrade, but it's coming shortly.


Thanks, I didn't see an obvious link (should have clicked "more"), wound up on NylasCloud page, which did have pricing, but that linked to a contact form.

Might be worth having a Pricing link/button next to download, and from the Free column, to the download screen.

Also, since the data is all in your cloud, would be nice to have a "web" version, so that I could use the app without needing to install. That would be ideal for me, a web-mail app that I can manage all my accounts from anywhere, even when I'm not on my home computer.

Just a few thoughts.


Thanks for the feedback!


Keep up the good work on N1, it's a great app :) I also enjoyed reading parts of the source code, it's awesome that you open sourced it!


Indeed. I am always surprised by the responsiveness of this app. Even when the rest of the system has slowed down to a crawl it's never too much to open up N1.


You guys are awesome and doing fantastic work. Thanks for the inspiration and for open-sourcing an amazing product!


Just a huge thank you for N1. It's fantastic!


I'm happy and grateful for any and all open source software, because it enriches everybody, well beyond the scope of its creators. But someone has to say it:

Electron is the cancer that is killing desktop computing.

It all started years ago with Firefox, whose interface itself was built using web technologies, in a "brilliant stroke." DOM, CSS, Javascript... maybe not HTML per se, but an XML substitute, and so on. I dare anybody say that Firefox's interface has ever felt as fast as IE, Chrome, Opera, or Safari (on Mac.) It never did and still does not.

Then someone at GitHub had the bright idea to take this "winning" concept and apply it to a developer's text editor, of all things! I still cannot fathom how Atom can have more than 3 users. Every time I've tried it, I've ditched it after 30 seconds. Slooooooooooow!

Fast-forward to 2016: now I see new Electron apps popping up every other day. Even something as simple as a text-only WhatsApp IM client, which could be written in a dozen of C++ files, is a bloated monstrosity that eats RAM for breakfast and contains an entire Node.js interpreter and a Webkit layout engine.

Cancer, I say!

Kill it with fire!


This attitude seems ignorant of the facts and the unfortunate state of desktop development.

Perhaps the cancer is the fact the desktop development community has had decades to settle on a decent cross-platform 'native' toolkit and completely failed.

Perhaps the cancer is 'native' developers spouting 'native is better' hyperbole, ignorant of the fact these supposedly better 'native' toolkits have been web-influenced for a long time.

- XAML from C#/WPF land being strongly influenced by HTML and CSS.

- Android XML being strongly influenced by HTML and CSS.

- Qt Quick being strongly influenced by JS and CSS.

- GTK+ embracing JS and CSS3.

- Everything else being awful procedural C++. Good luck maintaining that.

And all have massively inferior developer tools than Chrome devtools and/or far worse abstractions for the scene-graph/tree of elements than the much-derided yet very powerful DOM.

Native desktop is a mess. I'm glad we're seeing Electron expose it for the joke that it is.

You can hate web dev tech, but you can't claim that native desktop options are better. I won't be building apps 3 times or using any of these useless 'cross-platform' dev kits anytime soon, when I can build the same thing in Electron in a fraction of the time, and leverage the undeniably huge JS and CSS communities.

Also very tired of seeing devs use weasel-words like 'bloat' and neglect to put it into any context, like the fact that on the desktop 1. it ain't bloat if filesize is cheap, and 2. said filesize is comparable to the most capable cross-plat options you're supposedly arguing for (see Qt Quick).

Edit: Softened, expanded.


WinRT isn't embracing JavaScript because JS is so great, but to make the platform more attractive to web developers. Same with the HTML/CSS-style toolkits.

HTML/CSS, and Chrome tools, are definitely the better part of the web. The really terrible stuff are the JavaScript APIs. Of course there's JavaScript itself, which is gross. But there's no APIs for basic questions: where is the mouse pointer now? And is the mouse button down? How many screens does the user have? What is the width and height of this text? [1] Or anything Unicode-related. Or any sort of precise, pixel-accurate drawing. Web programming means resorting to terrible hacks all the time.

Maybe Electron has its own JS APIs that fix those issues, I don't know. But compared to making a traditional web app, it's a relief to use a real desktop API that actually has coverage of desktop capabilities.

[1] See the ridiculous lengths Atom went to just to figure out how wide a character is: http://blog.atom.io/2015/10/29/atom-1-1-is-out.html


> WinRT isn't embracing JavaScript because JS is so great, but to make the platform more attractive to web developers.

That may be true for WinRT, but I did not mention WinRT. XAML/WPF were around a long time before that.

> Same with the HTML/CSS-style toolkits.

Not sure what you're referring to but no, I don't believe that's true for the projects I mentioned.

Your complaints with JS APIs are warranted, but won't apply to 90+% of apps. Still seems like an overall win to use Electron/NW.js over any other option currently.


> Perhaps the cancer is the fact the desktop development community has had decades to settle on a decent cross-platform 'native' toolkit and completely failed.

Probably you are underestimating how complex is to build a GUI for different platforms and also underestimating how much browser technologies have been improved integrating zillion of years of experience.

Also, you can't compare how easy is to develop a desktop UI with Windows Forms in Visual Studio to how difficult is to build an HTML UI.


>> Probably you are underestimating how complex is to build a GUI for different platforms

Presumably you're getting at platform-specific differences. I'd suggest these are no longer as important as once deemed. Pretty much all desktop platforms are currently looking dated with respect to their mobile counterparts. So anything that looks 'modern' across all of them (e.g. good design + Electron) actually feels like sweet relief.

(If you meant something else, please correct me).

>> ... and also underestimating how much browser technologies have been improved integrating zillion of years of experience.

No, that's absolutely the point that I'm making. I'm suggesting browser tech is superior, largely due to the insane amount of engineering effort piled into it by Google et al.

>> Also, you can't compare how easy is to develop a desktop UI with Windows Forms in Visual Studio to how difficult is to build an HTML UI.

Yes I can, having done both :)


> Yes I can, having done both :)

Show me the tool that makes incredible simple to design that UI.


Windows Forms in not cross-platform. The VS UI to build it is great, but the end result looks dated and only works on Windows.

I say the two are comparable because, with talent applied, the HTML version looks better and works everywhere, so there's a net win for devs that embrace web.


I don't understand why people are so concerned with looks when the result from the alternative FEELS so bad.


So you agree with me, the current state of UI development for the web requires more tools that makes you doubt about the best option for development. I only mentioned VS as a clear example of a good design tool but QT also has an alternative.


And yet, nobody would use an Electron-based app over a native Mac app with similar features.


I would use Electron which I have developed for music using WebMIDI for Windows, Linux and Mac. It's fast as a native app, low latency.


Good luck to the typeless shit that JavaScript brought to us. It is never a revolution since it has been created. I do like or at least can use vscode, though.


I agree that Atom itself seems very slow, but VS Code tends to run great, and I really appreciate the feature set that it offers.

As it stands, it's not a great use case for many types of applications, but I would say that it's good enough for most of them. Beyond this, people are building useful things with it quickly. Far more quickly than they would be able to if they were targeting a custom UI platform, or with a lower level language like C/C++ etc. All this with the ability to relatively easily build for Windows, OSX and Linux deployments.

I don't mind people using XML based UI composition, as it works pretty well. Flex, XAML, and many other UI builders are XML based, simply because the structure corresponds well to the rendering hierarchy of components, and allows for easier understanding of their relative interactions.

I am half surprised there isn't a path towards a ReactNative for Desktop (OSX, Windows, Linix) at this point, that is similar to Electron, Node/V8 core, but with a common/reduced component set that just works.

It's worth mentioning that the underlying platform is C/C++ based with a very flexible UI kit (HTML) and a DSL (JavaScript + DOM) that is also flexible.


There is ReactNative for Mac OSX. https://github.com/ptmt/react-native-desktop

Not official though, but it's getting some use out there.


The recently announced React Native for the Universal Windows Platform would also support desktop.


Recently in a lobste.rs discussion thread, I wondered how people would react to programmers using PDF as an application platform: use a scripting language to update the content of the PDF file on the fly and in response to user events. I'm quite certain that most, if not all, users would shun these applications as they would be slow, unresponsive and ultimately trying to use a technology for static documents to develop dynamic and interactive content (i.e. wrong tool for the job). I feel that this is exactly what is happening with web applications and projects like Electron.

And then a user pointed out that Acrobat Reader can actually do that already [1].

[1] http://www.adobe.com/devnet/acrobat/javascript.html


Not a great example. Apple's graphics layer on OS X is very closely tied to PDF, and basically uses the Adobe Imaging Model that PDF is based on. It actually does include a PDF-based scripting language for drawing and updating shapes on the screen.


I'm glad to read somebody else who also shares my view on that.

HTML has been great to make the web great without microsoft attempt to monopolize it, but markup languages are useless as a file format you send across the internet.

Why? Because parsing text is, and will ALWAYS be slow. So either pre-parse html and put this in an OPEN binary file format, or burn it with fire.

Why can't investors and other developer take a damn hint that there is a reason smartphones use applications instead of web apps: html, dom, js, css all those things are slow and totally not well designed ! If you want to know more, start with that video that talks about the messy process that was HTML standardization https://www.youtube.com/watch?v=RH0o-QjnwDg

HTML is not a strict language, meaning it's EVEN SLOWER to parse.

Wake up sheeple (sorry that was unnecessary)


Sorry, this is just wrong. The time to parse CSS + HTML is negligible and isn't a reason native is better.

Native apps have a better foothold currently because mobile platforms had better support for their own native languages, than for sophisticated web runtimes like V8 at release.


The problem is "sophisticated". You can't have speed with "sophisticated" if that platform you are releasing software on is "sophisticated". At its base, the system must be simple enough.

If AT LEAST html would be a strict language like xml is, maybe that'd be better. But XML is not even human readable. YAML is.


The runtime isn't what matters, the touch-first UI toolkit and OS integration story is. The web came to mobile with lots of desktop baggage: scrolling, hover, "px", CPU-driven animations, etc. That's what makes it awkward on mobile.


i'm writing a desktop app right now. it's < 1500 lines of ocaml and gtk, compiles to a reasonably small native executable (3M after running upx), and is fast and responsive. it also has a grand total of one user, because i quail at the thought of getting it compiling on windows, and have no way to even know if it will run on a mac. had i written it in electron it would be trivially cross-platform from day one.

i have not done so because i actually agree with you that desktop apps built on a browser are a pretty sad end-user experience, but the lure of honest-to-goodness "write once, deploy anywhere" is hard to deny.


Quip show how it can be done better with their OS X app: https://medium.com/@btaylor/react-with-c-building-the-quip-m...

It's fast as hell.


I heard people made the same complaints about emacs once. Emacs is.. lightning fast compared to these new web ui editors.


Computers have gotten much faster since Emacs was born, but your point stands


For those that agree with this, I have a simple question.

If not Electron, how should one build a desktop app for Windows today? It seems the correct way is to use .NET and WPF if you want to take Microsoft's word for it. I've done this and it's installed on on 100k+ machines. In my experience, WPF is horrifically slow for users and uses just as much or more memory than Electron.

With that in mind, I don't really see how Electron has any downsides at least on Windows, and has plenty of upsides: build apps that respond to input much faster using a more familiar set of tools (JS, HTML, CSS). No .NET dependency that makes the install process a nightmare. No need for a custom update component (always very complicated, even for a super simple one) since Electron can just load remote resources. No need to worry about Admin privileges. Better support for monitor densities. Much better text rendering. So many things. I think Electron is saving Windows desktop app development, not killing it.


First of all, in my experience from many, many WPF and Silverlight enterprise applications: WPF is only horrifically slow when you don't properly thread your application. Classic Win32 (aka the million year old components System.Windows.Forms is built on) papers over a lot of mistakes in asynchronous threading and lets you get away with entirely synchronous code in places where it really shouldn't. WPF is a lot less tolerant of your code working in the wrong thread. Modern C# makes this a lot easier to work with given the async/await keywords, and ReactiveX is a joy to work with along WPF (say with ReactiveUI) if you get over the learning hump.

All of that said, even WPF has been superseded by the Universal Windows Platform. If all I planned to target was desktop apps on Windows 10+ I'd use the UWP these days. UWP has very similar advantages to Electron. (I really like Electron, though.) You can use familiar sets of tools, whether it's HTML/JS/CSS or XAML/C# or even XAML/C++. (UWP XAML is somewhat faster than WPF, but still just as sensitive to making sure you have your application properly threaded.)

If you can take advantage of the Windows Store or the Windows Store for Business (yes, that is a thing for enterprises to take advantage of) you get incredibly easy installation and upgrade.

Even if you can't use either sort of Windows Store, since the Windows 10 November Update, installs and updates are simply a matter of double-clicking an app package (.appx file). Users get a UAC-like prompt about the install, but don't need Admin privileges.

UWP has really good support for monitor densities and text rendering as it's meant to support nearly every combination of monitor densities you can possibly imagine, including the "Continuum" example of running an application on one's mobile device, miracasting the mobile device to a nearby screen to get a "full desktop" and moving the app to that screen.

The present of Windows desktop app development is the UWP. I'd still use Electron for cross-platform apps, but as a developer I like the UWP too. (My Electron apps I'm building for code sharing with Cordova hosts as well, so in essence I'm in a "Why not both?" situation and expecting to release both Electron and UWP options. I could even see encouraging people to use the UWP app on Windows over Electron. That said, I'd love a little better convergence between Electron and Cordova and could even see a more Electron-like API for UWP JS...)


There's no reason your choices have to be limited to the Microsoft-blessed solutions (Windows Forms, WPF) or Electron. You could use Qt or wxWidgets, and also potentially support other platforms.


I used to deride Qt for making application distributions 'bloated' due to shared library size, but with the habit nowadays to ship over 70 MB+ of Chromium in an installer bundle, Qt makes a lot more sense nowadays...


you are not very wrong. but still wrong.

desktop is hell. if I have to choose between wasting your memory or giving in to apple or android excruciating and closed developtment cycle, I will kil your memory anytime.


I run Slack, VSCode, my development server in Node.js and Chrome on my machine. Now count how many copies of Node.js and WebKit or Blink I have on my machine.

A shared browser engine could replace all of Electron apps (wink wink Chrome desktop apps) only if we had it right when we started.


There is another web-based option. Browsers will soon allow users to install (“progressive”) web apps on the desktop. It can already be tested in pre-release versions of Chrome (see this video https://twitter.com/simevidas/status/712473786910646277).


And this is only one example, there's NW.JS too, and Coherent Labs and Awesomium.. not to mention UWP apps... plus look at all the apps that leverage some sort of extensibility through JavaScript (Looking at you Creative Cloud and Office suites)

Burn them all down BURRRRRRRNNNNNN!!!

/s


Your entire rant is completely undermined by glaring factual errors. You should try Atom again (on a computer made in the last 10 years) and the try your rant again without that error as the centerpiece of your argument.


I think its beautiful and fast enough for nearly anything one would want to throw at it.

Also, unbelievably faster in terms of developer time.


While there are many awesome things about Electron, I still give native desktop app advantage. Native apps just feel better. It's all those ms (miliseconds) here and there that in the end make huge difference. Still best showcase is Sublime v Atom. I use Atom, because it's free and open-source, but when I fire up Sublime from time to time, it is amazing how better it feels. It feels right! Guess like everything else in life everything has it's good and bad sides.


I wish to go on a slight tangent and offer Visual Studio Code to your comparison, because while it's still slower than Sublime but faster than Atom, it also offers unique features that I predict won't be replicated by Atom / Sublime for awhile, if ever.


Code just looks ugly and Atom looks amazing out of the box. Possibly not the most important feature, but it does matter quite a bit I think.


I was always afraid to say it out loud, but look of text editor really matters to me. That's why I can't return to Sublime, because Atom got me used so much to that Material + One Dark combo that I can't go anywhere else now. My Vim config got quiet big over the years so now it looks really really nice, and uniform.

I think, because I spend a lot of time staring at text editor/terminal I really want it to look satisfying and pleasant to my eye. It is not main thing that decides, but definitely is up there.


I would say that Code looks "unlike Sublime Text", not ugly. But it was jarring the first time I opened it. Half an hour later though, I was fine.


Takes about 5 seconds to install a theme to your liking if you don't like the default one. I happen to dig it, personally.


Tried it. It feels different. I see Atom replicated Sublime's workflow, so I guess I am too used to that. I check VSCode from time to time, but not yet ready to jump on it. Only vim is permanent on my machine, all of the other editors are here to play with. :)


I also find Visual Studio Code's UI to be lacking in some ways, like the lack of some editing hotkeys or tabs. The reason why I'm pulled between Visual Studio Code and Sublime is because while Sublime is easier for me on some editing tasks, I find the "intellisense" feature to be very helpful for Javascript / Typescript.


Just a heads up: VS Code is starting to implement tabs in the next milestone (not sure what that means as for when users will see it, though). [0]

[0]: http://code.visualstudio.com/Updates


I love text editors, what features do you speak of?


Don't forget about how native apps can integrate into the unique features of the underlying platform.

On the Mac: Can an Electron app be scripted with AppleScript? Can it hand off to a mobile app using the Handoff API? How is the accessibility?

Windows has similar things with COM and Continuity. Can an Electron app play nice with these technologies?


With effort Electron apps can make use of Node native modules and do just about anything you want them to do.

In the peculiar Windows case, you can share much of your JS code with a "proper" UWP app as JS is a supported platform choice. With a bit of shim work you could even support almost all of the Electron API directly on top of the UWP.


Do developers put in this effort though?

I imagine that supporting AppleScript, etc, is a lot more common amongst developers that focus on MacOS vs developers that develop an application for three platforms.


That's a very different question.

As with any application platform, in some cases developers benefit from community effort and (ahem) platform effects: if, for example, a Mac OS developer really cares about AppleScript and builds a very good, simple way to provide it from an Electron application other developers might just do it because it is easy low hanging fruit to make Mac users happy. Theoretically it's even the case that if such a thing were used enough it might get baked into the Electron platform itself making it even easier to support.

Certainly if you can find a way to make it apply to multiple platforms (ie, "oh and this AppleScript tooling is similar for what we might want for IFTT support and these IoT platforms too"), then it has more value to a developer to support and makes it more likely that a developer will support it. (One example in Electron today is that most platforms have a concept of indicating progress status in their launchers/docks/taskbars, so Electron makes it easy to support all of the variations of that.) The complaint can be that in trying to build multi-platform supporting code is sometimes you get a "lowest common denominator" approach, but that leads us back to the original question that I answered which is that Electron certainly gives you the opportunity for developers to do the more specific things when they want to and isn't necessarily locked into "lowest common denominator".

From a general power user perspective: a cross-platform toolkit makes it more likely I see the application at all on my chosen platform; whatever the developers add to make it feel more comfortable to work with on my platform is a bonus.


> Can it hand off to a mobile app using the Handoff API

Looks like it: https://github.com/electron/electron/pull/5352


This says a lot, because Sublime isn't exactly fast. Electron is resulting in simple yet extremely bloated, battery killing apps.


Sublime (3) is incredibly fast, both at handling huge files, indexing file names in huge directory trees, files with huge lines, complicated syntax highlighting... you name it. In my experience it felt faster than MacVim (which it supplanted) so I don't know what you're talking about.

I tried both Atom (ditched it after 30 seconds) and VS Code (tried to use it for a few days) but they cannot compete with a well-written native app.


I can definitely see a niche in which Electron serves well.

However, it seems weird that when talking about mobile apps, the PhoneGap/Cardova "web wrapper" concept is derided as awful compared to native code or maybe cross-plat frameworks. From my anecdotal experience, those same people tend to think that Electron or NW.js are the greatest thing since sliced bread.

Electron is PhoneGap for the desktop. That's not necessarily a bad thing or a good thing, it's just a thing that makes sense in certain use cases and not others. The fact that web wrappers have different levels of "street cred" across mobile/desktop contexts feels more subjective than objective.

I suspect it's simply a matter of the younger crowd having more exposure to native mobile development, and little or no experience with native desktop development... so this discrepancy reflects those different comfort levels.


> the PhoneGap/Cardova "web wrapper" concept is derided as awful compared to native code

Yes, but mobile and desktop are quite different. For one, desktop has a lot more power - one of the biggest issues with PhoneGap etc. is that it's just slow, and, particularly, single threaded. That doesn't matter so much on desktop.

Also the other complaint is that PhoneGap doesn't use native UI components. Desktop has a huge variety in UI compared to mobile (think Microsoft Word vs Photoshop) - another "not native" format isn't quite as notable.

More importantly, though, is that developers hate PhoneGap and the experience it provides. I'd be interested to see the results of a survey where normal users are given a PhoneGap app and asked to point out what's wrong with it. I suspect many would think it's just fine. Not great, but fine. Similarly, if you asked anyone about the Slack desktop app I suspect they'd say it's fine.


I am genuinely curious, but why would you consider it not as important on a desktop to be fast or easily multi-threaded?

Especially the latter is really puzzling to me.


And this isn't just desktops. We're also talking about laptops, and Electron based software completely disregards battery life concerns.

Chrome (technically not Electron but it includes all the same problems) and Spotify gobble down enough power that I make a point of not using them if I'm away from my power cord.

Here I thought the gradual year-over-year percentage increases in battery technology were going to get us better battery life, but it turns out we'd rather just write shittier software.


IRT Battery life concerns - Electron utilizes OS based power management and will auto-sleep the app.

What other battery life concerns do you have that are automatically solved by another framework?


I couldn't tell you precisely why Chrome has comparatively bad battery usage, but it does:

http://blog.getbatterybox.com/which-browser-is-the-most-ener...

Even if you just leave it sitting in the background with one tab open, Chrome uses more power than Safari. I'm currently measuring an "Energy Impact" of 1.9 vs 0.1 for that test.

I don't have any hard data for Electron apps, but my experience is that they're worse than their native counterparts. For example, Spotify (playing offline files) vs iTunes.


The slower your application, the more battery it will consume to do the same task.

A JS+HTML application will be slower than a C++ application that uses the OS's native UI toolkit, and therefore will consume more battery.


Why does Chrome use up so much battery?


I'm not saying that being fast doesn't matter on desktop, I'm saying it's a lot easier to be fast because desktop CPUs are faster. I'm not saying that an optimized experience doesn't matter, just that it's less important than it is on mobile.


Ok fair enough, I get what you're saying.

My point is that tools like Electron are actually making it harder to do fast and multi-threaded code on desktop compared to other (native) options. So in that sense Electron's just as "bad" as PhoneGap on a mobile device: it actively hinders developers that want to build decently performing applications.

This even happens with applications that are considered "toy" in this thread like Atom: Performance is really much worse than other editors like Sublime or TextMate.


> My point is that tools like Electron are actually making it harder to do fast and multi-threaded code on desktop

Absolutely. Electron is worse than native, I'd never disagree with that. But I don't think people are looking at Electron and saying "hmm, shall we do Electron or native?", they're saying "oh great, Electron means we can make a capable cross-platform desktop app, something we don't have the time nor budget to do otherwise".


Nothing precludes an Electron app from being multithreaded (though WebWorkers, child processes and more) or relying on native components to improve CPU intensive tasks.

If someone is wanting to release a shitty application, they're going to do so irrespective of Electron availability.


That's true. It's an enabler for some companies, which can only be applauded. I'm not sure I'm too happy with the "worse is better than nothing" mentality I guess, but that's a more general problem :)


How does the existence of Electron decrease the ability to use other tools? It only offers another option... Just like .Net/Java do, both of which have disadvantages over C/C++ and the like.

What it comes down to in the end is, is the trade off worth it. With Electron/PhoneGap and the like, you have a much faster path towards an application. Web tooling is broadly understood, and a lot of that logic/workload can and often is already done, and being able to reuse it is helpful... Having a stack that is closer to the rest that you are using anyways means less disconnect.

It's not for everyone, but in the end it doesn't stop anyone from using C++, Go, Java, C#, Python or a number of other languages/tools.


I don't use Electron and haven't been following, but isn't Electron a UI only framework?

What I mean is what is preventing you from writing a C/C++ library, installing it down with your Electron UI and having the Electron App call out to the high performance .so?

PhoneGap gets a lot of hate because it's _slow_ and single threaded in an environment that is starved for resources. This can impact user experience even in _just_ a UI context. On a desktop, a single core is many times faster and there are much greater resources so I don't see it as having as large an impact on UI (if any at all noticeable user experience degredations). This is of course provided Electron is (or can be) UI _only_.

Just curious :) since I have never really heard of Electron before this.


The underlying JS engine is, iirc Node based... you can definitely use/utilize C/C++ modules/packages there... and very little is stopping someone from doing that. There are also child processes (and iirc, web-workers). While a Process !== a thread, on some OSes they are more similar or less in terms of creation cost. RPC/Communication channels are another issue combined with message serialization/deserialization which is the biggest cost to overcome with this type of model.


While I guess you can do that, most developers using Electron are so familiar with HTML/Javascript/CSS and related web technologies that building a C/C++ module for the bulk of their app might seem only a step above going "full native".


Just want to point out that the browser, and electron, and even node.js are multithreaded... it's only the JS engine itself that is a single thread. Asynchronous code and the UI engine itself definitely runs and interacts across threads. Also, there's also WebWorkers (while not great, can work in some cases).

There are also native modules for Electron/Node which can work in background processes.

In the end, for the most part, in most applications, there isn't much logic that actually takes advantage of multiple concurrent threads for logic, and I/O is already multi-threaded.


Well, he is presuming that the increased performance of a typical desktop makes the performance difference smaller. Considering that Atom performs pretty well even on my five year old desktop, that seems like a reasonable assumption. Although I think this is discounting the fact that the performance difference between desktop and mobile platforms is shrinking every year.

I agree with you with regards to multithreading, though. It seems like that is actually important on both the desktop and mobile for compute intensive tasks.


The red herring in the original comment is that Electron apps can't be multithreaded. They absolutely can be - through web workers, child processes and more. They can also fall back to calling native components for CPU intensive tasks.

Just because Electron is used in a technology stack doesn't automatically mean that the developers are going to be lazy.

Lazy devs be lazy, bro.


Desktop processors generally have much higher single threaded performance. Thus apps can more often afford to take a performance hit on desktop than on mobile.


I think that's where we have a different opinion. The performance incurred by Electron applications is larger than I care to afford them, even on my speedy desktop.


Well, the same actually largely holds for me. Low responsiveness is something I despise in applications. However, the general principle obviously stands: if you have more hardware performance you can be more inefficient and still have good responsiveness.

Electron happens to cross the threshold for sensitive users like you and me, but for a large number of users it seems the step in performance from mobile to desktop is enough to buy you the "Electron/PhoneGap/Cordova abstraction" (seeing as how there are popular Electron apps but few for PhoneGap/Cordova).


Does Electron have native UI components? I use Atom/Nuclide daily and it looks like a web app to me (aside from file requesters).


Native for where? You can always use stylesheets to adjust the appearance... you can even have targeted stylesheets for the different platforms. That said, "native" is pretty subjective, as windows has many "native" look/feel over generations... Office 2000 vs the latest or Windows across the same timeline... there's also GTK vs Qt on Linux, and their themes...

Electron is not native, and beyond that, there are too many variables cross platform for anything to look truly native everywhere even for a compiled C++ app without a lot of work. That said, you can definitely style to a platform more appropriately (again, there is work to that).


> I suspect it's simply a matter of the younger crowd having more exposure to native mobile development, and little or no experience with native desktop development...

Precisely this.

Mobile devs care about their artisanal/bespoke/authentic Objective-C or Swift code, while no-one really cares about Qt, GTK or wxWidgets in quite the same way.

There's social cachet to be gained by coming out in favour of native mobile development, while the same is not true for native desktop development.


They're obviously no majority but it's quite common for Mac dev to exhibit much of the same care seen in the mobile dev crowd. Given that all Objective-C developers were Mac devs before they were iOS devs, I'd bet that's where that bit of mobile dev culture has its roots.


I'm not sure that that's entirely fair. I for instance don't dislike Cordova for some philosophical reason, but because I have so far hated every single iOS/Android Cordova app - mostly for performance and polish reasons.

I do enjoy Visual Studio Code, Atom, Slack, and other apps built with Electron. Yes, people also use it to build horrible apps, but Electron has proven that it's capable of powering apps people love. I have yet to see a Cordova app people love.

TL;DR: I love various Electron apps. If I see an amazing Cordova app, I will reconsider my position towards Cordova.


Do you think this a bad app given it is one guy trying to target both iOS and Android, and both phone and tablets form factors? http://bland.com

This was already a ton of work. I shudder at the thought of having to have done this with 2 seperate native versions instead. I would have never shipped.


That link sends me to a page that says "Click here to buy Bland.com for your website name!".


How embarrassing... http://blanqd.com


Cool. You might also want to update the link in your profile :)


Ugh. Autocorrect strikes again!


Cordova apps performance is the main reason I dislike it. It's wonderful in principle, but when every Cordova app I try seems to have issues like delay and malformed UI components, I find it difficult to appreciate.

Electron has been the basis for several great applications though, just looking at their website[0] you can see a good number of apps that look and run great. Discord[1] and Gitkraken[2] among them, for starters.

[0]: http://electron.atom.io/

[1]: https://discordapp.com/

[2]: https://www.gitkraken.com/


I wonder if it is a sample size issue here: the number of Electron apps in the wild is currently fewer and the number of well written apps for seems like something of a statistical anomaly. Meanwhile there seem to be a larger overall number of apps written with Cordova/PhoneGap and the ones everyone notices are the ones that are poorly written. I'd wager that the Cordova apps that are well written are mostly invisible, even given how well most people think they recognize "native" widgets in mobile, the gap between HTML5 performance and native performance I think is narrower than a lot of people give it credit.


> given how well most poeple think they recognize "native" widgets in mobile

Every time I've opened a Cordova app I haven't known it was done in Cordova, but immediately thought the app was acting very oddly. Checked the source and yeah, there it is. Cordova.

That's not to say that every Cordova app is bad, I'm sure there some that work well, and if I had a need for any of the example apps in their showcase[0] I would have already tested some. HTML5 performance isn't so much the issue as the implementation of the wrapper. Electron stands as a testimonial to the capability of web technologies as an application platform, it's the history of Cordova applications, even in the last month I have tested an up to date Cordova app, and it just doesn't hold up to the hype. And I'm someone who really wants cross-platform web-based development on mobiles to be great.


I don't think it's the same people that dislike Cordova and like Electron at the same time. Usually the native-only crowd is against the bloat and performance issues that these wrappers bring in general but of course it is more of a problem on mobile where resources are way more constrained and good UX at the same time is a lot harder to do.


Yes.

The most relevant use case is getting away from different browsers.

You doing your web-app, make it responsive and give people who are like "We want to use IE5" an electron wrapper for the web-page.


Not me, usually such applications don't get to stay around on my hard disk.

Currently I am using Visual Studio Code, because it is one of the best IDE experiences for when I need to play around with Rust.

And being pragmatic, I rather enjoy the productivity of VS Code for Rust than being religious about it and losing the said experience.


I think it's because many web apps wrapped by PhoneGap/Cordova are not optimized for touch and UX expectations on a mobile device. I've seen plenty of these "apps" which didn't even bother to properly deal with the tap delay.


desktop is not so cpu constrained, so perceived performance of electron is "fast enough" but on mobile need native code and APIs to get there.


I've been building on Electron for the last 18 months (@Nylas), and it's really impressive how far it's come in the last year.

Coming from native Mac OS X development, Electron is an breath of fresh air. There's an incredible amount of energy and momentum in the web development community these days, and things like Flexbox, ES2016, React, and ESLint make it possible to ship fast and iterate quickly. Who would have thought JavaScript would be achieving what Java/Swing set out to do in the 90's?

I've had a chance to work with the core team on a handful of bug fixes and new features, and they've been incredibly kind and welcoming. I think Electron will go far as an open source project, and I'm excited that GitHub is growing it beyond Atom.

If you're in the SF Bay Area and interested in learning more about Electron, there's a meet-up coming up later this month! http://www.meetup.com/Bay-Area-Electron-User-Group/


I would argue that what Java/Swing set out to do in the 1990's was done already. You can ship Swing apps and make lots of money selling them to lots of people - JetBrains being a case in point. You don't get many people starting new projects that way (and Swing has been replaced by JFX anyway), but this seems more related to fashion than the merits of the various technologies.

The energy and "momentum" in the web community is something that has been discussed extensively on HN and elsewhere, so I won't comment on that. Suffice it to say that motion is not always the same thing as progress.


Let's be fair and admit that the typical Java app doesn't have all the features of a modern Electron app.

For instance, I downloaded Atom and after starting it, it wanted to connect to atom.io and then Google analytics. Now Google not only knows which web pages one visits, but also which apps one uses. Electron is win/win - for web developers and Google, of course.


Hah. In fairness though, most apps do want to report back usage stats and other telemetry these days. That doesn't sound entirely unreasonable.... though it's conventional for desktop apps to ask first (perhaps one reason people developers like web apps, the social conventions are different)


It is not allowed in the EU to gather data without informing the user and (in some cases) requiring opt-in. I think this is a very sane decision, even if it makes developers uncomfortable, because it is a privacy issue.

It is not usual to gather telemetry on the desktop, with perhaps the exception of some AppStore apps. Of course now that Microsoft got greedy and web developers are starting to develop desktop apps, we might see a different trend.


That depends on the data. I believe Atom uses the analytics privacy feature that deletes the last digits of the IP. That way it doesn't fall under the privacy directive.


Looking at Electron apps, like Nylas N1, one quickly notices they feel very uncanny, not at all like Desktop apps.

You practically have a window frame inside a window frame even! http://i.imgur.com/2C769ex.png

(Speed differences, the theming (dark theme for the whole UI, except for some electron apps?), etc are also issues.


Spotify and atom and slack feel like native apps to me.


Atom and Slack don't "feel" normal to me, they feel sluggish. They also take up a lot of resources (CPU, RAM). With what I'm running on a daily basis, I need all the resources I can get.

I think lpsz said it best, "It's cool for developers. It's not cool for the users". I'd qualify that with "It's cool for web developers".


Atom hovers at less than 5% usage between at least 5 separate workers for me. It's no 'ed' in terms of RAM but if it's under a gig it's fine by me. Certainly better than IntelliJ was in that respect.

Works pretty perfectly with rust as well. I have both a vim and an atom rust setup and they have near total feature parity.


A chat app having to show a loading bar when switching between conversations is in no sense of the phrase "like native".

Neither is a text editor that can't show letters as fast as a person types.


You are talking about Atom ? I've never had that problem, weird


I've experienced this with Atom. Seems to happen when the syntax highlighting code spikes the CPU usage as it attempts to highlight what you've typed and as a result the app waits for the highlighting code and your most recent keystrokes show up with a noticeable delay.


I get this in Visual Studio and occasionally in WebStorm too. C++ and Intellij-based Java apps.

Not the only one: http://stackoverflow.com/questions/19617670/why-vs-2013-is-v... http://stackoverflow.com/questions/20545435/why-is-the-new-v...


I had this with the ternjs plugin. Out of the box atom is pretty snappy on OS X. I haven't used Windows in a decade but I often see comparisons to Visual Studio accompanying complaints about Atom so my best guess is that it's either due to environment or a heavy plugin.


Coming from native iOS development (with extensive and still current experience in web) current web development is an absolute horrible mess.


Am I the only one unhappy with the trend of moving toward web-wrapper applications? As a developer, I also love the idea of cross-platform, and of more elegant frameworks, but it pains me to run things that are slower or hog the battery.

* JavaScript-heavy Spotify now vs. Spotify a few years ago

* Atom vs. something like Sublime Text

* Or, Slack that takes the cake especially if you log in to multiple Slacks.

It's cool for developers. It's not cool for the users.


It disappoints me as well.

Electron apps don't appear to play nice with the underlying API.

Take Spotify and Slack, for example. It makes sense that it should expose its API via AppleScript (on Mac), COM (on Windows), and DBUS (on Linux). These let you do neat things like, for example, use a PowerShell (or bash or AppleScript) script to update your Slack status to the name of the track that's playing.

Whether you'd WANT that specific functionality or not is beside the point, the fact that the functionality exists means that people will do cool things with it. More importantly, it means that people will do things the developer never thought of.


Except, the underlying backend of an electron app is a local node.js server. It's not only easy to open up a local API for an Electron app, it's platform independent.


Platform independence is nice, but generally that means it plays poorly on every platform.

Looking at Atom's API docs, for example, tells me that there's a very rich API that doesn't appear to be exposed in any way that's native to the underlying platform.


> Am I the only one unhappy with the trend of moving toward web-wrapper applications?

No, you're not. In fact, every time any link shows up on the Hacker News front page that has to do with using HTML/JS/CSS to build native applications the comments on it are usually dominated by people who are "unhappy with the trend toward web-wrapper applications".

> It's cool for developers. It's not cool for the users.

Here's the thing, if it's not cool for developers, then it might not even get built, and that's really not cool for the users. So if I had to choose between less performant code but more software options for users and more performant code but some software people really want or need not being developed, I'd choose the former.


You're not the only one. I'm very unhappy with this trend myself. Just when you thought people can't invent any new ways of slowing present machines down to a crawl, this happens.


I used to think faster computers meant faster programs...


well, the programs are faster to develop


Slack and Spotify are two examples of apps that have gotten worse and worse. Slack is CPU heavy as hell. Spotify is laggy and feels like a website rather than a native app.


Here's the thing: What's the #1 application that people use today on their desktops? Browsers.

There's a really high chance that you had another browser process open that was dedicated to writing your comment. Mobile included as the HA app is a Cordova-based solution.

But you feel compelled to say that thing that you used to accomplish your reading and commenting task was somehow slower and hogged your battery.

It got the job done didn't it?

Further, what's the #1 tech that some really smart people are focused on optimizing because of its usage. Yeah, again, the browser.

Show me another standards-based general UI stack that has had as much man hours dedicated to optimization... AWT/Swing/JavaFX? laugh. WPF, also really slow. WinForms? Not a lot of dev going on there at the moment.


The problem with Electron isn't just the fact that it's browser based. It's that it's a different browser. If I run slack, spotify, atom, and an actual browser all at once, my computer is going to slow to a halt. What electron needs is some way to run in concert with my actual browser, or some kind of hub process that coordinates them to reduce the absurd memory and disk space footprint.


generally Chrome and IE/Edge spawn separate processes per tab for isolation, but will sometimes group them based on some conditions. On the flipside I'd hate to have some 3rd party program bring down my browser.

So I get what you're saying, but the worst case is that your browser will do the same thing for each tab.

Software like Excel which will spawn a different instance of Excel for each workbook, even though it could theoretically be a single process... so it's not like native apps are a panacea in your argument.


An internet comment is a great example of a use case the browser is good for because it's low effort, low in specialized skills, and disposable.

Now we're talking about writing applications with web technologies for high specialized skill and high effort tasks, e.g., code editors, photoshop clones, etc... Which is what a lot of us are skeptical of. These "professional" applications are designed to reward a huge investment in muscle memory, if you are putting so much effort into learning an application, you don't want the return on that investment to be stunted by limitations in the technology the tool is built with.


Not following that last statement. There's no guarantee if I build my desktop application with XYZ framework that some technological limitation will crop up with it.

How much emphasis is being placed on JavaFX/Swing/AWT these days. Not so much. WPF? Microsoft has said that "...we are not investing in any major changes to WPF"

There is so much effort being placed in HTML/JS optimizations by WK, Blink, Edge folks that it's hard to find another framework with as much emphasis placed on it.


I'm talking about limitations in web apps that exist right now. For example with browser-based apps:

* Lack of data ownership, how do you export/backup?

* Poor keyboard shortcut support, e.g., constant conflicts between the browser itself and the app being run in the browser

With Electron based apps:

* Performance obviously, this might get better in the future, but that's a big bet of your time investment in learning and building on the tool. The fact that Atom is slow on a top-of-the-line machine is concerning. Sure that'll improve in time, but what if I also want to run it on more constrained device, tablets, etc...

* Electron apps still have a long ways to go to support basic platform expectations, e.g., on OS X Atom doesn't Services, AppleScript, or piping to the command line utility.


Qt 5 and QML. GTK on Linux...


>Qt 5 and QML. GTK on Linux...

List one that is MIT licensed...


Qt 5 is LGPL 2.1+ (not a problem unless you need to statically link).

GTK+ is LGPL 2.1 (not a problem unless you need to statically link).


And wxWidgets is LGPL with an exception for static linking.


It feels like the inmates are running the asylum to me.


I know this is not really electron's fault, but could there be way to shrink these run times to a lot smaller?

Like Whatsapp App on Desktop you literally have a 60MB download and 200MB install just for a screen that is EXACTLY the same as the Web Version of Whatsapp.

While I dont expect all the apps are like CCleaner or the old uTorrent which is only a few MB in size, 200MB is just redicously large.


Usually people copy most of the node_modules over.

Ideally it should be run through webpack/etc and only a bundled, minimized version of the app is shipped. In practice some modules may have native compiled addons.

I'm working on an app right now and it ships at 247MB which is way too big.

release/darwin-x64/PlaySPLOM-darwin-x64/PlaySPLOM.app/Contents

107M ./Frameworks

12K ./MacOS

81M ./Resources

52M ./Resources/app/node_modules


related: I realized that many people including myself made mistakes with .npmignore and accidentally include docs directories. that is a lot of bloat.

a node module should be just runtime required code and LICENSE


^ This. Setup your .npmignore before publishing!

Also, before packaging your Electron app use something like gulp to exclude problematic files like .md and anything else unnecessary.

There are other common tools like browserify that can still be leveraged.


Not trolling, but do you find 200MB is actually a burden? Here in London cable or fibre links means that downloads in seconds.

EDIT - Ok, sorry, it seems quite a few people do have pretty horrendous bandwidth issues.


Other people have covered the bandwidth angle, but I also think the size itself is an issue because of memory. And the more Electron can load into memory out-of-the-box or via default coding conventions, the more opportunities for poor memory management from developers. Since Electron is being used for utility apps, its bloat multiplies on a system with a lot of apps on it.

Also, Electron's size means more power draw. When I want enough battery life to do some work and still watch a long video afterwards, I habitually close Slack because it makes a worthwhile energy difference. The app's size reduces my engagement with the app after install. I'm aware my behavior is unusual, but developers do need to keep this in mind, especially as Windows and OSX make app energy use more transparent.


Not trying to defend Electron or larger app frameworks here, just trying to learn.

How do you make the link between app size and power draw (as opposed to some other aspect of Electron causing draw)? And, what are you comparing Electron's power draw to?


It might be a stretch to assume the effect will be significant, but...

A larger application presumably uses more RAM to itself (especially if its instances of node/chrome/libraries are distinct and so do not share pages by reference or in a copy-on-write manner with other similar applications) so there is less room for cache and buffers so the machine as a while is likely to be hitting disk more often and so consuming more power that way.

Loading the app will obviously involve more IO too, though hopefully that is not a regular occurrence for a full desktop app (it may be for a smaller utility program though) so the running costs should dwarf any start-up costs over time.


Personally I think frameworks like Electron lead to huge bloat in terms of download size, disk space, and system ram. However there is no doubt that it increases the accessibility of developing applications for multiple platforms.

I think the following is a great narrative on why it can matter though: http://blog.chriszacharias.com/page-weight-matters


Does download size necessarily mean more system ram usage?

I agree on page weight, but somehow I'm more sympathetic to downloading apps, perhaps because it's just downloading in the background, rather than me waiting to read the content.


From what I understand, each instance of an electron app essentially needs its own copy of the electron framework to work (which includes a web renderer, and javascript engine). So we're talking at least 50MB per instance, for applications which may have been 10MB if written in a native language. When you start running many applications, it can certainly add up. Users do notice this kind of stuff, they are just too adaptive to bad user experiences.

As for downloads, I remember using dialup and only getting one 1MB file per hour. It would take a lot of patience to even download a 10MB app on that. I don't tend to leave my computer on downloading overnight these days though, and I 'only' get 1MB/s (dslreports.com says I'm "faster download than 60% on DSL in australia").


I have found these nodejs desktop apps to use less RAM than other more traditional Toolkits like Qt. I can live with more disk space being used if it means better memory usage


Extraordinary claims such as these need at least some sort of evidence. It does not make sense intuitively that a browser engine has a lower memory footprint.


It could be that it's the other programs that are also bloated.


That's good news. I did some searching to find some real comparisons, but most of the links I found were related to memory leaks (nothing from 2016 though, perhaps outdated).


There is a point when convenience for lazy developers becomes bloat. Emacs is probably at that point - a runtime feature-full enough that you can get both a web browser, mail/news reader, presumably an irc client as well as a half-decent editor in a few tens of megabytes. Significantly more than a small talk runtime, that fits it's own blitter, dcvs and full IDE in under 10 MB.

What does the order of magnitude really gain the end user? A slower, less powerful GUI system?


Not trolling, but do you realize that not every human lives in a major European city connected to a fiber link?


Last time I was in London, company headquaters had worse connection than my old home one in Poland. Generally whenever I went for business purposes, I was always surprised how slow business connections were...


Of course :) I lived in Sydney for a year, but even there I had a 24Mbit ADSL2+ line, which is still under a minute to download this.


You were comparing London (huge metropolis) with Sydney (another huge metropolis).

Those data points aren't really as different as you seem to think :)


Sydney certainly didn't seem like a 'metropolis' when I was there :) But seriously, Australia in general has poor internet bandwidth, by dint of its limited transoceanic cables, so I thought it was a fair comparison!


200MB takes around 1hour to download where I'm living.


I don't think people believed I wasn't trolling. Sorry.


I don't think download speed is that much of an issue, whether or not you have good internet service, because I think people are willing to wait a little to download an app. The issue is more app size on modern computers that come with limited size SSD's and steep upgrade tiers.


Not everyone has a fibre connection. I get 250KB/s at home.


My parents, who live in a village in the English countryside, get similar speeds, and a 5gb monthly cap.


Woah - I know many don't have fibre/cable, but I thought at least ~20Mbit speeds were the majority. Where are you may I ask? Is that common where you live? Is it costly?


It's pretty common in some major part of of Asia. It does get costly from where I am (Malaysia).

http://www.statista.com/statistics/381388/asia-average-inter...


Actually 20Mbit/s is a lot even in germany... More likely to see 6 Mbit-16Mbit while some cities have 25/50/100 but if you are living outside of bigger cities (which most people do) you will end up between 6 Mbit-16Mbit and some area's are worse.


Very common in "rural" UK, where rural means 5 miles away from a city. You'd expect to pay £20-25 per month for the privilege (although note that this includes a "line rental" charge paid to the layer 1 provider - BT - of approx £15 per month)


200MB is my 4g data allowance for 1 month. Yes, for 95% of use cases 200MB is an unnecessarily large burden.


If your app becomes successful, and you host it on a CDN, 200MB will consume a lot of bandwidth, creating costs that may prevent you from distributing it for free.


I live in zone 2 in London, and the fastest broadband I can get is ~2Mbit. Even in major cities, good - or I would argue, even acceptable - broadband is not ubiquitous.


So do I (in fact, on the cusp of zone 3) - so I'm really curious why that's the fastest you can get?


Not the OP, but in the same situation until I moved: Close-ish to an exchange (so no street cabinet on the line for fibre equipment), no cable coverage (so Virgin is out), out of range of wherever the hell Relish's tower is, and ancient wiring in a block of flats (so can't reach sane ADSL speeds).


I'm in the same position. BT recently declared that they might install fibre to my street some time in 2017 though, so that's quite exciting.


BT declared that they would install fibre to my street in London five years ago. That didn't happen.


200MB is how much space eclipse takes up


"Electron has lowered the barrier to developing desktop applications". Nope, I don't think so. Perhaps for web developers.

For non-web developers, there are already well-suited technologies to develop desktop applications: Swing, Qt, Cocoa, GTK, WPF/WinRT, and so on. Maybe theses technologies seem less sexy but there are here from the beginning to do that kind of job.

Please, use the right tool for the right job.


Why didn't you quote the full sentence: "Electron has lowered the barrier to developing desktop applications, making it possible for developers to build cross-platform apps using HTML, CSS, and JavaScript"

I don't see anything wrong with that statement, Electron really lowered the barrier of entry by allowing using HTML, CSS and Javascript to build cross platform apps, before you had to learn a new language to make it happen (Swift, QT etc).

> "Please, use the right tool for the right job."

I would rather use a tool that I know and build something functional fast, than spending many months learning new language just to make my app cross platform and losing interest because of that.


You realize that maybe for someone, C++/QT isn't a new technology but HTML/CSS/JS are? Or neither are new, or both are new? The person who replied to you was right, you are making the assumption that everyone knows the web stack and knows nothing else.

Electron tries to break the same barrier WebForms did but in the opposite direction. Hopefully it turns out better and doesn't result in a bunch of shitty desktop apps like WebForms resulted in a bunch of shitty web sites.


In all fairness, that's still a lowered barrier. The barrier is the sum of all parts, if desktop gui dev is easy for systems programmers and really hard for web devs, and this project makes it easy for web devs, then it has objectively lowered the barrier for entry. It doesn't matter if it's still just as hard for systems programmers.


I never thought I'd see something that made Swing seem approachable, but now we have it.


It's wrong because that tends to persuade developers that there is one tool for every situation.

If you build something functional fast with your favorite tool (not suited for the job), then you will probably spend many months maintaining/hacking your codebase to keep it functional and well designed.


It's still better than spending many months learning new language and not building anything functional at all. I would rather build something functional fast and see if it works and has demand.


If someone spend many months learning a new language, but still can't be able to build something functional with it, I think he has a bigger problem...


Its more about why would you go spend few months learning something, if you can build it in few days with electron.


Because you can't.

An Electron app is not equal to a native app when it comes to UX and UI. Right off the bat: they require more resources to run, thus making your computer slower, a laptops battery last less on a single charge, and don't look and work like native apps thus requires the user to learn a new paradigm.

So instead of you, the developer, using a couple of months to learn a new paradigm, you put that burden on your users, and end up with something that is a whole lot worse than standard native apps on Mac, Linux and Windows.

If you only have 1 user, that is no hassle, but if you have 5 million users, that is a whole lot of time that a whole lot of users needs to spend collectively because you are lazy and want to ship something fast instead of shipping something great.

And no, I have never tried a great Electron app. I don't think they exist.


> If you only have 1 user, that is no hassle, but if you have 5 million users, that is a whole lot of time that a whole lot of users needs to spend collectively because you are lazy and want to ship something fast instead of shipping something great.

Exactly. That's the externality a lot of software companies nowadays generate.


"they require more resources to run, thus making your computer slower, a laptops battery last less on a single charge,"

But yet you used a either a browser or the HN mobile app (cordova) to post here... guess that means function > fitness.


That is one browser. Because of work, I also need Slack. That is two.

You get the picture.


I've also got Outlook open, so that's at least 25.


What new paradigm? Almost every computer user out there knows the web paradigm. They use it on every platform.

The barrier to entry for Electron apps is 0, the same as for native apps.


What are you talking about? Are you saying that because someone is adept at browsing Wikipedia or Hacker News, they intuitively know how to use Spotify and Slack and Atom?


How are you evaluating tool fitness here? The ultimate criteria for fitness are organizational / business goals, and that business or organization may have to juggle various constraints. Electron offers extra flexibility for businesses to make tradeoffs on app performance and size versus engineering cost, and that's its most important value.

At first glance, Electron apps should be more maintainable, not less, because it's one toolset for multiple platforms, which should translate to faster development time and less total cost of maintenance at the tradeoff of app performance and size.

Also, whether an app is difficult to maintain ought owe more whether (1) you have multiple diverse codebases and toolchains to maintain, and (2) that you have a disciplined engineering strategy.

Again, whether or not Electron is the right tool for the job is a business decision based on business constraints.


> How are you evaluating tool fitness here? The ultimate criteria for fitness are organizational / business goals, and that business or organization may have to juggle various constraints

Unfortunately, usability and ergonomics are rarely reflected in business "fitness functions" (hell, even making an actually useful tool rarely is these days, thanks in part to marketing having better ROI than delivering value). Business people take care of business goals, and I think it's our responsibility as developers to make applications that don't suck, whether or not it is reflected in the organizational "fitness function".


It's certainly lowered the barrier of entry for me, and I'm no web developer - my background is mostly back-end Java. Sure, I started out by making websites when I was younger, and a few of my jobs have involved a bit of front end, but I'd be surprised if there are many developers that don't know the basics of HTML, CSS, and JavaScript.

Using web technologies to develop a GUI has been so much easier than learning a new toolkit, or even language. For one thing, some of the options you mentioned are OS specific. There are benefits to OS-native toolkits, but as a one-man team with a small project, the benefits are small and the time investment large. With Electron, I can build on Linux and release for Win/Mac without any concerns.

Qt is the best option of those you mentioned, and I considered it. But I was never great with C++, and learning a whole new markup language (or being tied to Qt Creator) for the UI was an extra barrier for entry. And I've often found that Qt programs don't look or feel right outside of Linux.

Personally, I find developing a UI on HTML/CSS/JS much easier than any desktop UI toolkit I've tried in the past. Updating the UI from the code, and calling code from the UI is s simple, because that's what it was designed to do. And having a browser console makes debugging and trying things so much easier.

I was never a fan of using JS for anything but websites before, but I decided to give Electron a try and I'm a convert. Perhaps there's enough of a speed difference between JS and native code that it would matter for more complex programs, but for my uses I don't notice a difference, thanks to the speed of JS engines now.

Maybe from someone that's starting with no coding knowledge would find Qt and C++ just as easy to pick up as HTML and JS, and certainly a C++ developer would find Qt a better choice. And sure, I don't expect anyone to be able to build Photoshop on top of Electron. But there are plenty of programs that aren't that complex.

While in theory I agree with not using the "new sexy technologies" for the sake of it, and "using the right tool for the job", I don't think that applies here. It works both ways, don't stick with old technologies just because that's what you're used to. What specific benefits do you get from using one of those toolkits for a simple desktop program?


I think it's easy to argue about tools, but take a look at popular desktop apps these days: Slack, Atom, VSCode, Spotify, WhatsApp Desktop... they're all built on Electron or the Chromium Embedded Framework. It seems the community has spoken, and no longer considers Java / Qt the right tool for many jobs.


Comparing the developer experience between them makes it hard to argue that HTML/CSS/JS are the right tool for building GUI apps. The awkwardness of the web 'platform' is just huge, in comparison, even ignoring the performance issues. Atom and VSCode, for instance, have a long way to go to catch up with the real Visual Studio or IntelliJ.

The real reason you're seeing apps based on Electron these days is that it's easy to hire HTML/CSS developers. That doesn't mean these are good platforms though. I remember when the bulk of apps were being written in Visual Basic because it was easy to hire VB devs (lots of people learned VBA via MS Office).


"Atom and VSCode, for instance, have a long way to go to catch up with the real Visual Studio or IntelliJ."

You're right. They need to catch up to using 5.8 GB for Visual Studio and 480MB for IntellJ to start. :)


I think you have a very narrow view of "the community" and what constitutes "popular desktop apps".

What about applications like Photoshop, Premiere, Cubase, Logic? Basically anything that does more than show a couple of editor panes. I'd love to see these kinds of things built in Electron but as far as I can tell this has not happened yet. In these areas languages like C++ and frameworks like Qt are still really really popular. Not to mention embedded development, of course.


> What about applications like Photoshop, Premiere, Cubase, Logic?

That's the difference between toys and tools. Most of the popular applications are toys, and this saddens me a lot personally, because humanity is wasting the potential it has with all that cheap computing available.

> I'd love to see these kinds of things built in Electron but as far as I can tell this has not happened yet.

I don't see it happening any time soon. Web is not meant for serious tools. Compare Microsoft Office and Google's butt office suite. One is a tool, other is a toy that looks nice for simple documents, but is utterly unusable when your document/spreadsheet grows beyond more than a couple of pages.


> Web is not meant for serious tools. Compare Microsoft Office and Google's butt office suite.

Well, isn't that an ambiguous claim with a weak anecdotal evidence. What is a "serious tool"? We have our email, crm, analytics, (only) shop, document versioning, etc. online. Actually, the native applications I use are just Visual Studio (can be replaced by code), Sql Management Studio (many web-based alternatives) and the browser itself - that being the only type of application I use with no web-based alternative, which could be seen as an operating system.


> Well, isn't that an ambiguous claim with a weak anecdotal evidence.

Try working on a 20-page document or 5-page-long spreadsheet and see how long it takes before you get pissed off at the performance. Unless you're oblivious to it - I'm starting to believe more and more people don't even expect anymore that computers can work without constant lags and pauses.

> the native applications I use are just Visual Studio (can be replaced by code)

Now can it, really?

> Sql Management Studio (many web-based alternatives)

With even remotely similar feature sets?


We have a giant list of archived support tickets in Office 365. They can be navigated nearly as fast as they can be navigated in native Excel app, through the 365 web app.

I replaced Visual Studio already with Code for my personal projects. I expect it is just a matter of time before companies start to consider doing that too. Is it feature-complete? No, but not because it is an Electron-app, but because it's just young.

SQL Server doesn't work on platforms other than Windows so the motivation for coming-up a feature-complete alternative is little. I could even then find a couple promising projects with a web search. For other databases such as Postgres and Mongo, there are many alternatives which provide more than their native GUIs. Rethink's main GUI is web-based, for example. A database management interface isn't challenging to implement as a web-app because web-apps are limited toys, but it is hard to do right in general.


SQL Server now runs on Linux.


> That's the difference between toys and tools. Most of the popular applications are toys, and this saddens me a lot personally, because humanity is wasting the potential it has with all that cheap computing available.

I always wonder if pretentious people realize their pretentious and simply don't care, or they're actually oblivious. Perhaps you could enlighten me?

The difference between a "toy" and a "tool" is whether or not something is mainly for fun or mainly for being productive. It has nothing to do with the process used to build it.


I think the previous author's point was more on point without using judgement-loaded words like "toy". There certainly are definitely classes of applications where sheer computing complexity or responsiveness probably means that we're a long way off from using web wrapped applications (eg Electron). High end graphics editing, video editing, and music DAWs certainly qualify in this category.

Then again, from what I know, Premiere, Photoshop, and DAWs like Cubase and Logic are straight-up C++ applications, and don't even go into Java / Qt territory.

I would say that something like Google Apps vs Microsoft Office is a lot closer than it used to be. Native-app Excel sheets for instance still have the edge in speed overall, especially for large datasets (say, >10,000 rows) better, and Excel has a pretty significant edge in my opinion for analysis (pivot tables, charts, etc.). Google Sheets however are very capable for a large percentage of documents, with the added benefit of being so much easier to share and collaborate. Neither use case is a "toy" scenario in my opinion.


Maybe I'm conflating several of my issues with webapps in the word "toy". One thing is ergonomics, bloat and lag issues. But the other thing is that webapps trying to fill in the role that originally belonged to desktop apps are more often than not pretty dumbed down. There are several reasons for that - one is performance, which makes you unable to add more complex features without making the entire webapp unbearably slow. Another is the business approach of sticking to MVPs and not really progressing beyond them.

Also, lag issues are not really limited to high-end graphics / video editing. Sure, lag/low performance makes those tasks basically not doable in the browser. But even "ordinary" webapps - like word processors or issue trackers - are annoyingly slow. Take Jira for example - I'm probably wasting a few (billable) hours every month just because it's not a desktop app. So are all of my co-workers. It's most likely also the reason people tend to batch time reporting and do it once a week or so (it's much less distracting then), which as a result precludes management from having access to up-to-date information about time spent on tasks.

Trivial inconveniences can have non-obvious impact.


> Take Jira for example - I'm probably wasting a few (billable) hours every month just because it's not a desktop app.

I think you'll find that Desktop apps often have to communicate with with centralized servers as well.


I definitely get what is being said here about web apps feeling slower. I've personally found desktop apps to in general be more responsive / quicker than web apps, and I think it's more than the communication layer. (Actually, I think REST is far more responsive than some of the previous middle tier communication methods used by desktop apps...).

From what I've heard (no in depth knowledge so I welcome corrections), the DOM / CSS model itself really wasn't designed for fast, responsive applications and thus tends to under-perform in that department. So even a fully internal network app with comparable communication speed may seem slower on the browser from the get go.

Many web apps often also tend to be a little bit laggy just based on their cloud based nature. Load a random spreadsheet on Google docs, and you are probably talking 100-200 requests and (depending on your network) perhaps a 5-7 second delay. Change a tab, and you probably have another 2-4 second delay. Compared to the 1 second load time of a spreadsheet and nearly instantaneous tab switching time on a native spreadsheet app, it feels slower... especially for the power users, I'm sure...


Communication overhead (which could be reduced with some additional caching client-side) is not the only source of the lag. User interface is a problem too. Sure, with enough work you may be able to overcome the problem in this (and similar) cases - but web apps are usually developed around a particular style, which involves AJAXing around way too much data way too often.


> I always wonder if pretentious people realize their pretentious and simply don't care, or they're actually oblivious. Perhaps you could enlighten me?

They're just tired and try to highlight some problems that others don't care about.

> The difference between a "toy" and a "tool" is whether or not something is mainly for fun or mainly for being productive. It has nothing to do with the process used to build it.

The difference is the goal - is it supposed to help people be productive at their task, or is it just supposed to make such impression while in fact being there to extract money from naive customers? (Or is it a worse-is-better half-assed 20% solution?). Whether you like it or not, performance is a big part of usefulness of application. I brought up MS Office and Google's cloud-based solutions for a reason - only one of them can handle the load a professional user needs to handle.

Quite often it's literally like a difference between a metal hammer[0] and a plastic one[1]. Both can, in theory, be used to drive nails, but there is kind of a difference in performance.

[0] - https://upload.wikimedia.org/wikipedia/commons/8/84/Claw-ham...

[1] - http://thumbs.dreamstime.com/z/plastic-hammer-2181534.jpg


So what you're saying is, all tools need to be designed for the power user or they're toys. I guess I should return my $10 hammer I bought from Home Depot and replace it with the $225 Stiletto TB15MS solid titanium hammer (http://www.amazon.com/Stiletto-TB15MS-TiBone-Titanium-Straig...).


No, I'm saying that plastic hammers shouldn't be sold in hardware stores, and also that trying to push plastic hammers on normal users and $10 hammers on power users is a very bad trend.


For 99% of business documents, Google Docs works just fine.

Your needs are different, and that is cool - but it does not relegate web apps to "toy" status.


My needs are pretty standard. I run an NGO and have some amount of paperwork and data tracking to do in a word processor and spreadsheet application. Due to the collaboration requirements, we're stuck with Google cloud suite (the choice was made back when there were zero reasonable cloud-enabled alternatives). Google's office suite is theoretically capable of doing most of the things I need[0], but the omnipresent lag when you try to work with a bigger document or (more often) several documents at once is very annoying and slows things down. Half a second here, five seconds there, and it all adds up to significant frustration.

There's a significant difference between "theoretically X can be done with it" and "it is useful for doing X". You can drive nails with a plastic hammer after all (and most people don't even need the "additional" feature of pulling them out).

[0] - which is partly because I reduce expectations of what I can do. Think of it as generalized Blub paradox - you think in terms of the tools you use. Get a better tool, and suddenly you can do more, do it better and do it faster.


Meh. Microsoft Office pisses me off more with its constant crashes and weird bugs than Google Docs does. The latter has less functionality, but at least it's stable. Not to mention the vast majority of users don't need the advanced functionality anyway. If you're doing serious publishing work, sure, go ahead and use MS office. But 90% of common use cases are easily satisfied with Google Docs.


> Microsoft Office pisses me off more with its constant crashes and weird bugs than Google Docs does.

Crashes / weird bugs and MS Office... that's something new to me. I always considered MS Office to be a set of some of the most stable applications I've ever seen. Do you do something atypical, so that the bugs/crashes could be related to a platform or some rarely used features? I'm asking out of curiosity.

Google Docs et al. don't just lack advanced functionality, they lack a lot of quite basic functionality too. But my point wrt. webapps is also one of ergonomics. I do a lot of work in Google Docs and Spreadsheets due to external reasons, and I absolutely hate the experience. No matter how fast a computer I use, the lag on the Google's office suite is very annoying and distracting. Like with some IDEs which are slow enough to make one unable to ever enter the state of flow, Google's spreadsheets routinely double the time I am spending on a task due to simple lag on almost every operation.


>>Do you do something atypical, so that the bugs/crashes could be related to a platform or some rarely used features? I'm asking out of curiosity.

Not that I can tell. I mean I run it inside a Windows 7 VM, but other than that, nothing atypical.

One example of a bug that I can think of (because it happens consistently) is that Outlook 2013 taskbar icon shows the orange envelope to indicate that I have unread mail... when I don't have any. It drives me absolutely bonkers. I've also ran into more serious issues, for example yesterday when I pasted something from a web page into MS Word and it froze and crashed.


The world development community is a weee bit larger than five. Neither is text editor and wrapper for a website "many jobs" ;)

I've seen many complaints about Spotify on e.g. Reddit - specifically about the fact that it's no longer native. Seen also many complaints about bloat and slowness in Atom & VScode.

I understand why this toolkit is chosen, but companies can only push so much before the customers also push back against the decrease in qulity.


I love your comment. But it basically says something else : programming is a lot about fashion. And nowadays, HTML/JS/CSS is fashionable and Qt is not anymore.

Everybody can yell that Qt/Gtk or even the MS stuff is the better tool for desktop apps, it won't change anything.

There's 0 objectivity in the choice. The young boys just think in HTML/JS, so we'd better adapt :-)


So tell when a Photoshop, a real Visual Studio, a SolidWorks, or any big/professional software written with Electron-like tech will be out there.


Atom and VSCode despite all the hype are subpar editors. Slow and resource hungry. Maybe suitable for script kiddies of today ... Slack is by no means a good sample of solid engineering. Spotify last I checked was native app written in c++. What's App is just wrapped website.


Spotify used to be fully native, nowadays the UI is done in various web technologies while the heavy lifting (streaming audio etc) is done in c++.


Your examples kind of prove the opposite point, these are not ALL popular apps, they are just popular "toy" apps. You weren't able to give a single example of a popular major application.


How exactly are Atom and Code "toy applications"?


They are vastly less complex than other applications listed here (e.g. Photoshop).


There are many web based ERPs and CRMs, some of which are way, way more complex than Photoshop. Given one has access to their algorithms, I don't see why Photoshop would be impossible to implement on top of WebGL. Photoshop UI doesn't have the "native feel" anyway. I think it's just a matter of time until Adobe comes with a 90% feature-complete web-based PS.


I'm sorry I wasn't more clear but I'm not talking just about the UI. It's also being able to give realtime feedback and do hugely CPU consuming tasks, which is essentially the core of Photoshop.

Can you give examples of ERPs or CRMs that are "way, way more complex than Photoshop" though? It would be nice to be able to compare.


By "toy" I don't mean that their purpose is necessarily entertainment, but that the difficulty of building them is not comparable to many popular desktop apps - the list is not representative. Like building a toy plane vs a real plane - the difficulty, not the purpose. Major computer games are not "toy apps" in this sense. Sorry if I was unclear.


As as webdeveloper, I am now starting to think about desktop applications, where I would have ignored the platform before.

It's not at all about how sexy a technology or framework is. I just think I can do a better job in a framework that's adapted to my skillset, instead of adapting myself to a new framework.


I'm someone who's cut his teeth developing desktop apps the 'old' way and came rather late to the whole modern web-development thing. And I have to say that going zero to a good enough prototype app is dramatically easier with web based stuff in most cases. Sure going from good enough to a polished high performing product can often be a massive pain, but that's a different story.


It didn't used to be that way.

You used to be able to use Delphi or VB6 to make working desktop apps in very short times. I'm sure other will reminisce about other older desktop techs that were a breeze to use.

MS severely dropped the ball with WPF by making it have a very high learning curve just when javascript was really exploding. So not only was it easier to distribute web apps, they were cross platform and it was easier to make them too (although the massive pain of SPAs has changed that).

There was also Adobe Flash Builder that very briefly looked like it would be a competitor when Balsamiq was a big new thing, but it never really took off (only other thing I've seen use it is salesforce's SOQL tool). At that point everyone hated Adobe though, so it didn't have much chance.


Yea, for all the flack VB gets, it was pretty amazing. VB4 was what got me from writing silly little scripts for my own amusement to writing applications that could actually be used for something.


Honestly, at this point, HTML + associated frameworks like React/Angular are more mature for a lot of UI development than Qt is. Well, if you buy into the FRP/stateless UI things anyways.

Though interface builders help a lot, I've always had a problem building more dynamic interfaces through any of the native tools. React, for example, makes that a lot easier.


How can something that's ~3 years old be more mature than something that's 20 years old? Even QML is 7 years old at this point and that is reactive.

Try to stay at least a little bit realistic...


Mature and old are not the same thing. I don't think TkInter is stronger than React +Electron for building stable, large apps despite the large age difference.

One thing is that React is the newest iteration of production-quality declarative UI management. Angular, Backbone, a lot of stuff came bdfore. And all that contributes to a mature understanding

That being said, I forgot about QT quick. That is also pretty powerful stuff. Though the web influence seems there ( correct me if the causality is wrong).


While I consider web-tech in native a cancer I can't help, but agree. There is no good cross platform native UI library today. Few that are are stuck in 90s metaphor or poorly designed. Which I think is partly the reason why html-css-js is spreading everywhere.


Which ones have you tried?

I ask because I quite like JavaFX. The developer/documentation website is fusty and old-fashioned looking, but the tech itself is just really solid. You can tell it's been made by people who have spent their whole careers doing UI toolkits.



If it has become easier for web developers to create desktop applications the statement still holds.


> Please, use the right tool for the right job.

Which part of Electron makes it wrong?


My biggest gripe with Qt is HiDPI support which was introduced just 6 months ago, so quite late. It feels cumbersome compared to HTML/CSS which have native HiDPI support built-in for years. Also the implementation in HTML/CSS is straightforward. You don't need to think about it a second, it just works. Actually this is my number one feature of web tech, it's HiDPI ready and websites and apps like Slack look always slick, crisp and clear, on any platform.

With Qt, just watch this 30 minutes presentation about Qt and HiDPI, while ok there are some parts which unnecessarily complicate matters: https://www.youtube.com/watch?v=2XPpp4yD_M4


What do you think the suitability of Electron is for software that is designed to provide revenue with per seat licences and no service component? I.e. 'traditional desktop app'. It seems to me, given how easy it seems to be to copy and modify an Electron application a third party could always copy an application, whitewash it and capture a portion of the market.

The counter point to this is that ownership of the developer brand and distribution channel is which will always drive sales. I'm not sure which aspect is more important when planning a technology platform and revenue model...


People can crack/clone desktop apps regardless of the language they're written in. You can certainly add the same types of protection to Electron apps that might be found in traditional native apps, but it just makes things harder and not necessarily impossible.

One of the benefits of Electron is the updater system, which allows you to release updates pretty frequently. You could tie that to the paid user account and just innovate faster than people cloning your app!

Electron also uses a specific binary packing system (ASAR) to ship app code, so cloning is also a bit harder than just copying a bunch of JS files. https://github.com/electron/electron/blob/master/docs/tutori...


Cloning is as simple as "npm install asar && asar extract app.asar", modify what you want and "asar pack" again. So the packing system is really no protection in itself. See https://github.com/electron/asar


Trying to stop piracy through client-side technical means is always going to be a losing battle, becasue you can't trust the client. But you can embed native modules in Electron apps, so you can do whatever you were planning to do in native code to "verify" the installation, and then load JS only after decrypting it in native code. Compiling your licensing / decryption code for 3 platforms still beats having to maintain 3 copies of the whole app's source.


I don't think the issue is piracy per se. People want the ability to compile down the JS into native code for obfuscation reasons to prevent/discourage derivative works.

I know you can do that to some extent by minifying your JS code and I also know that no obfuscation or compilation technique is going to 100% prevent derivative works, but it helps a lot and it's a feature that many wish the Electron team would look into.

NW.js has it, but it's super hacky as it uses (abuses) the V8 snapshot feature to deliver the functionality, seriously degrading performance in the process.


As others have said, you can never really truly protect things on the client side no matter what language tech you use.

We used Electron (well still called Atom-shell back when we started) for building Spectrum (https://www.devspectrum.com) which we charge per seat and it's been a great development experience and it's certainly performant enough to handle tons of local logging capture/filtering.


That seems like a legal problem rather than a technical one. People who want to crack or even rebadge your software will always be able to.


This is true given a dedicated enough programmer. Since most programmers aren't quite this dedicated, however, this isn't 100% true.

From what I am aware, in lower level (C++) development there are some definite strategies to "deter" piracy even at a technical level. Stuff that Urs (developer of u-He software synthesizers) talks about here, eg:

https://www.kvraudio.com/forum/viewtopic.php?f=4&t=400768&st...

Basically: A) Make the protective schemes as non-obvious as possible in a disassembler (obfuscation, making the copy protection part of some core routines etc.) B) Provide a few obvious "sweeteners" that "pretend crack" the software for a period, but then show a "whoops your copy is pirated here's a offer to purchase it" later. (EG: a time bomb.) This allows the crackers to get their 0 day warez thrillz, without actually truly cracking the program.

Of course, none of this is 100% insurmountable. That's not the point of this exercise. The goal is to basically make cracking the software a chore more beyond usual, and therefore, not worth the typical cracker's time.

I am not sure how one would approach this with managed software or web-wrapped software (although if you can run the copy protection in a native module, that would be the way to go.)


I've been thinking long and hard about this and I think one strategy, how stupid it might sound, is to release the software unfinished then make updates like SaaS.


Congratulations on reaching 1.0. Electron is really interesting, but until memory usage can be curbed, it's going to be a limiting factor.

I have been going back and forth with Slack over their desktop client; on Windows when signed into 5 groups it uses 1GB RAM. For a rich-chat client.

And if you're thinking "But RAM is cheap these days" -- well yes it is, but by the time you've got 15 Chrome tabs open, a Jetbrains IDE and 3 VMs, plus assorted other software running, 16GB disappears very fast...


Slow, sluggish, resource hungry and looks alien everywhere. Yeah right. Progress ... If there is one thing its done is lower standard for native applications everywhere.


As someone above said, they have achieved what Java/Swing set out to do in the 90s.


Just like websites. They'll never succeed. /s


Just because something is "succeeding" it doesn't mean it's not bads qualitywise or it provides a good experience.

(Case in point - Windows Vista :P )


Quality of implementation has some correlation with market success, but ultimately there are many variables involved.

Just the other day someone had detailed that they have a business based on Delphi with some ancient database. Can't be rewritten, but it brings in revenue.


> Just the other day someone had detailed that they have a business based on Delphi with some ancient database. Can't be rewritten, but it brings in revenue.

And quality-wise it's probably better than any alternative "cloud-based" solution they could buy these days.


Websites don't take up 30+ MB disk and 100+ MB RAM (well, not in Firefox anyway, and that's another thing Electron is missing: switchable runtimes and rendering engines, unlike the web)


In a way, Electron is web enabled as a web browser and very stable across platform. Native application might not be 100% reliable.


it's better to have a slow app out for users than having no app at all.


Depends, it might prevent somebody from building a proper app because the slow one is "good enough".


Spoken like a true assembly programmer.


Yeah, because Facebook/WhatsApp can't afford a native desktop client.


Burn this.

Instead, please, can any investor just hire any computer science PhD (who eventually specialized in compiler engineering), and tell him to work on PREPARSED or COMPILED HTML, and make a browser module out of it, for the sake of speed and memory footprint?

PLEASE. I BEG YOU. DON'T EVEN TAKE CREDITS FROM ME. IT IS SO WE CAN SAVE THE WORLD.


Think about how much time people spend in front of 24" screens with a keyboard. "Desktop", or whatever that evolves into, is overwhelmingly where real work still gets done. For as critical as that environment is in the modern workplace it's historically been drastically underserved by this community.

Yes, there are a lot of tools like Swing, Qt, Cocoa, GTK, WPF/WinRT, but their development communities are much smaller than the javascript/web ecosystem. They also create enormous portability problems, particularly in an environment (especially in the business world) so heavily dominated by Windows machines.

This community is acutely aware of what happens when the barrier to entry is lowered and the development tooling improved. The tooling that Electron provides via Chromium is also something that should not be understated. Chromium's dev tools are remarkable and improving every day. Few other ecosystems, especially old desktop ones, have debugging environments as rich. The painting performance / profiling tools alone go to great lengths to keeping everything running at 60fps. Furthermore modern CSS layout engines like FlexBox give you an enormous head start on a notoriously difficult problem and is a joy to work with when you don't have to worry about browser compatibility.

I will admit, the getting-started cost of Electron is high. Shipping all of Chromium and Node is no small feat and frankly probably not suited for a minor utility. However once an app crosses even a modest level of sophistication the benefits of this environment are definitely worth it. There are also several specialized tasks that Node probably isn't suited for. Luckily, since you have full process control and the ability to compile native modules any additional specialized task can be run on the side.

The past 18 months working with Electron at Nylas have been some of the most enjoyable development experiences of my life. Much of the crap that frustrates people out of web development (compatibility issues) go away. Being able to build an app at the core of people's day-long experiences is deeply satisfying and something I'm indebted to the Electron team for.

If you're in the Bay Area and still have questions or are just curious, come join us at the Electron Meetup on Wed May 25: http://www.meetup.com/Bay-Area-Electron-User-Group/events/23...


One issue I have with Electron is that if I put my computer to sleep without restarting it and have all the applications up all the time, Electron apps gets very slow and sluggish and lags very much. Slack is a good example of this.

I have to restart my computer every now and then in order to keep using Slack and Atom, because otherwise it lags so much. I don't know, I think I prefer UWP apps instead.


VSCode doesn't seem to suffer from this and isn't it also running on Electron?

Maybe it's more of a memory leak thing that TypeScript doesn't have.


No idea, don't use it. But the two applications I use that I know use Electron suffer from the issue I am experiencing.


Pssst. TypeScript is JavaScript.


My team is trying to use Electron to build and deploy apps for Linux, Mac, and Windows, but running into issues with the Mac build. Getting a dmg built on Linux (our build server) is apparently not trivial. Is there a docker image or some other project that wraps all the dependencies up to build Electron apps for all major platforms?


We've open sourced the build scripts for Nylas N1, which actually just builds on Travis/AppVeyor for Windows, Mac, and Linux. We originally had an internal Jenkins server doing the builds and it was way easier to just configure hosted services to do this for us. It's free if your project is open source, and you can do some clever things to keep signing keys private and include private source paths during compilation.

Here's the grunt task for Mac DMGs. The parent directory has a similar script for Windows and Linux (and lots of other utilities too). https://github.com/nylas/N1/blob/master/build/tasks/mkdmg-ta...



Electron is really cool, unfortunately its startup performance is slow (several seconds on a ~2010 machine). That's why I had to pick Qt for a file manager I'm launching... (https://fman.io)


Every Electron application I've used has been sluggish and straight up pathetically slow compared to any native counterparts. I think there are two reasons its picking up steam:

* Your can now make your web devs (HTML/CSS/JS etc) do your application development as well

* General popularity of web development is exploding

* There's no comparable free, permissive native framework. The closest thing is Qt and its LGPL. No one wants to touch the GPL.


It would be nice if Electron could enable cross-platform apps, written in languages other than javascript, that compile to native for the back end and to javascript for the front-end.


The big thing with javascript is that it has truely become a platform 'agnostic' language. It covers all bases in frontend (web, mobile and desktop) and backend development.

No other language is in such a unique situation, so its wise for Electron to be JS centric moving towards the future.


Why does it happen so often that the technically weak languages get picked and become widely used? Why Javascript? Is there something about technical superiority that makes less business value?


I think we can blame smartphone operating system developers for this. For so long they dug their heals in on only allowing certain languages run on their systems. But they also put a web browser on the phone, and then worked to make that browser match the desktop version as closely as possible. It was an escape hatch to be able to write cross-platform code, once and for all. Oh, sure, Android ran "Java", but it didn't include enough library commonalities with desktop to work. Same with iOS and Objective-C (which is practically unheard of outside of the Apple sphere). I've had far easier times getting one binary to run in Windows Mobile, desktop Windows, and Linux.

So I think there are very good social reasons why JS "won out." Perhaps it was the weakness of the language itself that made it possible. It didn't seem like a threat in 2008.


https://www.dreamsongs.com/RiseOfWorseIsBetter.html

tl;dr: Ubiquity is a feature. Implementation simplicity enables ubiquity by making it easy to port and easy to bring new people on board. Implementation simplicity also frequently results in technical inferiority, but it doesn't matter, because users would rather have substandard software that runs quickly on all devices they target than excellent software that is either slow or unavailable.


Honestly, I think JavaScript was just in the right place at the right time. If you haven't seen ES2016 yet though, it's really worth a look. Electron JavaScript isn't the jQuery crap of the 1990's. It's got destructuring assignment, classes, template strings, let / const, you name it...

https://github.com/lukehoban/es6features


I feel compelled to point out that jQuery 1.0 was released in August 2006: https://en.wikipedia.org/wiki/JQuery#History


The web browser being the right place. There still isn't any real competition there.


"classes"


It's not technically inferior. I think historically many have confused not-like-java with technically inferior in Javascripts case. Combined with the fact that people who make client-side JS are less Real Developers (no true scotsman would code in js!).

JS is a dynamically typed functional language. Not unlike Scheme or Clojure. It's long history has made the standard library be a mix of programming styles, but I usually make heavy use of Ramda or Lodash and other functional wrappers to get a coherent interface nowadays.

What was a mistake was including `this` keyword though. Never use it, just like you would never do so in Scheme or Clojure. Carthago delenda est.


>It's not technically inferior.

Come on. It has plenty of unique problems with no upsides. If that's not inferior, I don't know what is.


No upsides compared to what? Faster development time compared to Java, C-family languages is an upside. Faster VM (V8) than Ruby MRI, and just about every other dynamic scripting language, is also an upside. It's also an incredibly easy language to learn and write. Many of the weird inherent flaws went away with strict mode and ES5, ES2015 has helped make it much more elegant to read. Of course, you can always switch to a superior language like Elm that benefits from the same VM.


Oh, I did not mean to say that Javascript has no upsides whatsoever. It clearly does.

I meant to say that it has problems which have no upsides. By which I mean that it has certain weaknesses that contribute nothing to its good features and that could have been designed correctly without negatively impacting anything. They are just plain mistakes.


The unique problem you mention I think is vocal commenters that see "JavaScript" and immediately take a one-sided mentality against any tech stack that uses it.


Try to work with Javascript's arrays, it's a nightmare.

Fun fact:

  let list = new Array(5);
  list.forEach(() => { console.log("foo"); })
Will display nothing, if you want to properly initialize an array with a defined length, you have to do:

  let list = Array.apply(null, Array(5)).map(function () {})
I make web games in Typescript, and I get all sorts of problems like this everytime I have to work with 2D arrays, problems that I don't get when I do games in C# with Unity. Unity's modified Javascript actually implements better arrays and recommends not using Javascript's native arrays: http://docs.unity3d.com/ScriptReference/Array.html


You seem to be trying to fit a square peg into a star-shaped hole. Arrays in JS are actually misnamed, they are actually Lists. For game scripting you may want to make heavy use of Typed Arrays [1], which are more like the arrays you seem to be looking for.

[1] https://developer.mozilla.org/en-US/docs/Web/JavaScript/Type...


for loops will yield better performance and the result you want to get. If you're trying to log 5 times you shouldn't be wasting memory with allocating an array or needlessly calling the forEach function or needlessly creating a callback. You're just wasting garbage collection and cpu time with this


so use the more common

for(let v of list) { console.log("foo"); }

If you're saying that "initialize an array with a defined length" should be "initialize an empty array of 5 values of undefined" then yeah, but you can also use:

let list = Array.from(Array(5));

as new Array(5) creates an array of length 5, but each is a "hole"

I know the syntax is similar to C# or other languages, but because it's slightly different doesn't mean it doesn't bring anything to the table. JS or TS != C# in a browser the syntax is similar...


Yes as bengotow said, I don't think its a matter of whether the language is weak/strong, rather its just a matter of circumstance.

The holy grail of web development has always been the ability to write web apps that can run across all popular browsers. I think many have been waiting for JS to be the language it should have been for so long now. Its seems the time has finally arrived and BAM! JS explosion.

JS is not bad at all (JS now that is), its an incredibly flexible language. This obviously annoys many as there are no hard and fast rules for development (framework hell anyone?) but as a language you can apply it to most any environment.


JavaScript is like Java, but easier to learn, faster VM, no jars etc, and more powerful: foo.bar = require("http").server ...


Wagon actually does this with Haskell: https://www.wagonhq.com/blog/first-two-weeks-haskell-wagon


I just came across a great Electron app called Nativefier (https://github.com/jiahaog/nativefier https://news.ycombinator.com/item?id=10930718) last night. It's a super easy way to make dedicated browsers & launchers for certain web apps. (very anti-web, I know)

My first use case for it was making a dedicated Amazon Video client for my wife's laptop (although Nativefier doesn't have one of the necessary plugins) so we can have our regular Amazon accounts separate without switching credentials all the time. But I can think of a bunch more for this


Electron has gotten a lot of criticism for being bloated. Are there any good alternatives for making desktop apps that are scripting language based? I’d especially like to use Lua(JIT), but I’m not aware of anything anywhere near as reliable, cross-platform, easily deployed, and easy to build interfaces in as Electron. I’m not the biggest fan of the JS and/or the JS ecosystem, but I would love the speed, lightness, and convenience of another language (just look at how fast and lean Lua with LuaJIT is!) with the power that some JS tools like Electron have to offer.



You can use Lua with Qt (Torch has some bindings), but it's nowhere near as well tested.


Is there a "built with electron" type directory out there somewhere?




This is awesome! I wish I had something more constructive to say but thats all I could think of at the moment.


Are there plans for electron with the servo browser ?


I believe the plan is for Servo to support the Chromium Embedded Framework interface, so theoretically it could be a pretty straightforward drop-in replacement.


I think it already does support CEF to an extent - no idea if it's enough

https://blogs.s-osg.org/servo-the-embeddable-browser-engine/

https://github.com/servo/servo/labels/A-embedding


No plans, but it sure would be sweet, wouldn't it? :)


Interesting, reminds me a bit of XUL and XULRunner from the old days, which sort-of failed. What does this have in common, or is different this time?


Today's HTML, CSS and JavaScript is a much more powerful and mature platform than XUL ever was.

The number of developers with the skills to build a native-quality interface using the web platform is hundreds of times the number of developers who ever learned XUL.

Using HTML and CSS for desktop UIs is a proven pattern now. Even Apple used WebKit views for iMessage on OS X.


Yes, I've even done it myself a few times over the years. But one thing I don't like is that most don't follow the OS theme. I'm not a fan of every app having its own, ala "skinz."


Electron looks like it has for both worlds, but what is the drawback of this(kind of) system(s)?


There are a couple of things to consider:

1. Electron is not necessarily the best choice if all you want to do is "put your website in the Dock." In Electron, JavaScript on the page can do anything native code could do, like write to the filesystem unless you explicitly disable node integration. Just loading up your website inside an Electron window could be a disastrous security hole.

2. Electron apps run at least 50MB, and take at least 100MB of RAM. (Equivalent to one tab in Chromium)

3. JavaScript is single threaded. Node's event-driven / async design makes is a good fit for most things, but considers all work equal. You have to bend over backwards to do things that a nice threading abstraction would make easy (like Regexp find/replace in a huge directory tree. Atom actually spawns a separate process to do it so it doesn't consume the JavaScript process.)


Electron apps are huge and incredibly resource hungry. This makes it hard to recommend most electron apps.


Source? VS Code is taking up 26/86mb of memory and weighs in at 143mb on disk... not really the most CPU intensive program either


Non native UI. Probably not a big issue on Windows where every app use a different UI toolkit, but on OS X is kinda nice to have native apps.



That's even worse. The almost "native" look but with the wrong spacing, wrong colors, and wrong behavior.


You have to write Javascript.


Or Go, Dart, TypeScript, PureScript, Elm, CoffeeScript, Oberon, or any other language which can be compiled to it.


Or, create a C or C++ NodeJS module and use it from your JS, or interop using EdgeJS or python-shell


I am guessing I can use GWT as well, right?


And css...


I like the idea of making desktop apps with html, css and JavaScript. I just wish that Electron/Atom wasn't so horrible slow. It shouldn't take me more time to open up a desktop app than a webpage.


Would a dynamically linked, system-wide Electron installation help with the extensive resource usage of Electron apps? It would decrease the installation size but what about the runtime performance?


not sure where the red herring came from. VS Code uses less system resources than a blank excel document for me. Opening up another tab in a browser can spawn another browser process, which is done for isolation.

Same example, 142MB is the footprint for VS Code. VLC is bigger.

Where is this "extensive resource usage" that people seem to be concerned about even apply to Electron? Metrics?

A similar paradigm would be to create a Chrome Packaged App, but you're going to still have the same resource utilization as another browser tab.


I find it more comfortable to make a GUI using HTML/CSS, but I wish I could use a more modern and more reliable language than Javascript.

Is there an equivalent to this but with Python or C# ?


Using a similar technique, you could use http://coherent-labs.com/dotnet-browser-controls/ but you'll also pay out the nose for it.


Oh, forgot about https://github.com/cefsharp/CefSharp, but theoretically anything that uses Chromium Extensibility Framework (CEF).


TypeScript?


ClojureScript


One of the things I really like about Electron apps is they look good consistently across platforms, which is something I don't often see for cross-platform apps.

QT seems to be the other major cross-platform framework, but I've never seen one that looks good IMO.

Would be very curious if any fellow HNers could point to good alternatives (preferably C++ based, but as I allude to, I'd compromise by using something like Javascript if it meant a better real world outcome for the user).


"looks constantly good" is debatable. I find that it looks generic and web like. It has none or very little native look & feel to it. Coupled with being slow, resource hungry long loading times ...


To put it another way, can you name any applications you feel do cross-platform right? Are there any example you feel tick all the boxes for you, and do they use any framework?


It's far from perfect, but Corel AfterShot Pro[0] is an example of commercial software that uses Qt and ships for Linux, Mac, and Windows.

Some of the imperfections I notice are:

* The options dialog has a lot of things that just look "different". The controls are native, but the way they're positioned, etc, clearly isn't. The Mac has a lot of common things, like which order the Yes/No/Cancel buttons would appear in a dialog box, that aren't done the same in AfterShot.

* Being a photo management/editing application, it naturally uses a dark theme that looks out of place everywhere. Adobe Lightroom and Apple's now-discontinued Aperture both do this. It seems to be a normal thing with this type of application.

* On Linux, the window decorations come from AfterShot, not from the window manager. It also has the Windows close/minimize/maximize buttons.

* On an old-enough Mac, the integrated GPU doesn't provide the OpenCL stuff that AfterShot requires. This causes it to crash at startup, whereas a real Mac application would tell the OS to fire up the discrete GPU.

* I seriously doubt that it exposes any of its API to AppleScript/COM/DBUS, but I haven't checked. I know that it doesn't register itself as a source for the system-wide photo browser on the Mac (as an example, Insert > Pictures > Photo Browser in Microsoft Word on the Mac will show your Aperture, Photos, and iPhoto libraries as whatever structure they have in that application, not just as files on disk).

[0] http://www.aftershotpro.com/en/products/aftershot-pro/


If you're based in San Francisco, come to our next meetup! We'll have a bunch of people working on and with Electron there.

www.meetup.com/Bay-Area-Electron-User-Group/


Related to another comment I posted here, what's the opinion lately on native controls/UI widgets vs something cross-platform like this?

It always used to be argued (and maybe still is) that using the UI framework of the platform is preferable, but IMO the results of Electron apps I've seen look great, and I don't find them confusing to use.

The reverse seems to be true on mobile platforms, where people seem to be preferring native UI widgets and behaviour.


I think you're raising a valid point here. Electron apps are not confusing because they do look like "applications" in the broader sense. Built on web technologies, they end up looking like your average well-conceived and well-designed website out there. And that look is something that all users have now become accustomed to, so it does help bridge the platform gaps tremendously.


It's too bad the titanium platform with desktop/mobile/js/web combo never got more momentum. Building a 'web' app - with php or ruby - and bundling as desktop app was pretty darn cool. I only dipped my toes in around 2011 or so, and was sad to see it never get more traction. :/


So CatLight [1] seems to be a C# app using Electron for UI. I'm assuming there's a local web server running, but I wonder how this works from a build perspective? I wonder if Electron can be built with MSBuild.

1: https://catlight.io/


On a slightly unrelated note, I love the theme of the Electron plot. Is there any place where I could find it?


Anyone with experience with Electron and NW.js have an opinion on which is better?


Hi, I'm writing a book comparing them both at the moment:

https://www.manning.com/books/cross-platform-desktop-applica...

Having built apps in both, my view is that if you want the tool that fits best with Node.js' conventions, Electron is closer to that philosophy. I say this because of the way that the Node.js contexts of the main (backend) process and the renderer (front-end) process are kept separate. This is different to the way that NW.js has managed to blend the Javascript contexts of both into one, which can lead to odd behaviour when it comes to apps that run with multiple windows.

In terms of momentum, Electron is definitely capturing the most attention and it looks like it will eventually become the goto framework for cross-platform desktop applications over NW.js, which is a shame because NW.js has been around for a while now and was the pioneer of being able to build desktop applications with Node.js.


If you don't have to support win32 platforms, I'd say go with Electron.

Other than that, features pretty similar.


Hmm? Slack's MacApp purports to use MacGap not Electron (https://github.com/MacGapProject/MacGap1).


https://slack.com/jobs/69902/desktop-application-engineer

"The Slack Desktop apps are built using diverse technologies such as Electron, node.js, ES6, RxJS, C#, and Objective-C,"


Congrats to the Electron community!

We've been excitingly using Electron at Wagon to build SQL analytics tools. We're using Haskell + React + Electron as our primary technologies: wagonhq.com/blog/electron


I haven't used Electron, but what about mobile apps? I have a need for an app that works on desktop and mobile. So is the recommended option Electron for desktop and for mobile PhoneGap/Cordova?


PhoneGap/Cordova apps are slow. Very slow. And even a hello world app can weigh tens of MB. Debugging is painful compared to a native app.

The thing is, you won't notice how bad the situation actually is until your code base has grown. Performance can seem acceptable at first, when there's very little code to load and run. When your codebase inevitably grows, you'll start noticing slow start up times (> 10 seconds) and a laggy UI.

If you have to do any computationally intensive operation, you'll have to resort to cordova plugins because JS running in the UI thread is a non-starter.


Have you try Android Studio?


Microsoft tried something similar years ago with HTML Applications (.HTA), essentially web apps that could talk to the file system. Didn't seem to work out, though.


Microsoft also had smart watches, mobile phones and tablets years ago, and none of them really panned out either. ¯\_(ツ)_/¯


Microsoft have too many mistep in technology over the years due to my perception that each products is a utilizes/tools rather than a products. Apple got the products right


Congrats! This is an awesome tool and I hope it ushers in a whole new generation of desktop apps!


"any application that can be written in JavaScript, will eventually be written in JavaScript" this seems to be more and more true and depressing. A JavaScript hegemonia.


[flagged]


This breaks the HN guidelines, which ask you not to call names ("you are acting like a child", etc.) in comments here. Please post civilly and substantively, or not at all.

https://news.ycombinator.com/newsguidelines.html

https://news.ycombinator.com/newswelcome.html

We detached this subthread from https://news.ycombinator.com/item?id=11674670 and marked it off-topic.


> I can write Photoshop with Electron if I live long enough to finish it. Hell, I can write it in x86 assembly. But why?

Writing graphics-intensive apps is actually the aim of WebGL.

> You are acting like a child

> That would be retarded

I would like to remind you that here, we try to keep it civil.


To me, unless things have changed, electron is crazy. Many people today use some sort of abstraction layer that generates their html/css. I really hope they move towards interfacing js or node.js directly with skia (which is the graphics engine for chrome and used by, I think, sublime text).


This reminds me of Shoes. Of course, Javascript isn't designed for simplicity like Ruby, and Electron is aimed at serious product development rather than novice and weekend programmers. The product design just isn't "there" yet if we are to measure it by _why's standards. But it's nice to see an ACCESSIBLE actively-maintained tool for making cross-OS apps that "just work" again.

In fact, _why released Shoes around 2007 and disappeared in 2009. To put this in perspective, Google Chrome and the 1st iPhone were released in 2008. The web standard mess (JS in particular) was only beginning to be untangled back in 2007. Maybe today's _why would have preferred to try and make Javascript more approachable rather than choose a simple language like Ruby and make it more powerful. I don't know.

At any rate, the trend for things like Electron is to become increasingly complicated to the point where it merits a mention in developers' CVs — as it happened with Rails and Node and countless other frameworks before. Hopefully at this point there are players with stakes high enough at making things accessible to push for an entry-level version of Electron. Maybe Codecademy or one of its cousins.




Consider applying for YC's Spring batch! Applications are open till Feb 11.

Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: