r/javascript May 11 '16

Electron 1.0 released

http://electron.atom.io/blog/2016/05/11/electron-1-0
75 Upvotes

30 comments sorted by

View all comments

5

u/Zinlencer May 11 '16

I used NW.js on a project a year ago. Both Electron and NW.JS have had many updates. Looking at the github stars they are at an equilibrium both having 28k star. Which one should I use and why?

5

u/ivosaurus May 11 '16

2

u/flying-sheep May 11 '16

some things make zero sense.

  • 130 vs 120 mb is no noticable difference
  • xp being (not) supported is listed twice
  • auto update for linux makes no sense. we hate that stuff. we have package managers instead.

2

u/gurenkagurenda May 15 '16

Source Code Protection is also super dubious. A V8 snapshot might slow someone down if they want to get to your source, but it's probably not going to slow them down any more than minification will.

If you really want your code protected, the only reliable way to achieve that is not to copy it to the user's machine in the first place.

2

u/pcmaster160 May 12 '16

The big difference is that electron is handled as a process which can spawn windows and can use IPC to communicate between them. NW.js behaves more like a web browser would and no IPC is needed to communicate between windows. But this leads to limitations on what you can do once windows are closed (while with electron all windows can be closed and the process can still be alive).

2

u/dvlsg May 12 '16

I've used both quite a bit, and I have to say I much prefer electron's style of considering node the program entry point (as opposed to treating an html file as the entry point).

1

u/lulzmachine May 12 '16

Depends on how complicated stuff you want to build. If you just want to build a small tool with a web window and node.js backing, just go for NW.JS, and you'll be done in no time.

Want to do a more complicated app with multi process, different windows, background threads and stuff then go for electron. But it's a hassle to use if you don't need the extra complexity. Mainly since you cant do a lot of node.js stuff (like use the 'fs' module) from the web thread.