you wish to create a native desktop application from web technologies, the open source world offers two main choices: NW.js (formerly node-webkit) and Electron (formerly atom-shell). Deciding which one to go with is not so obvious. That is precisely why I created the comparison chart found in this article. Hopefully, it will help you choose the right tool to build your next physical computing project. At this stage, the chart is a work in progress and needs help from the community. As I have used NW.js quite a bit more than Electron, this post probably suffers from my own bias. Please (respectfully) leave your comments, suggestions and corrections to improve it. In addition to the chart, I will also compile a list of various other key differences that may influence a first time user’s choice. Again, your input is most welcome.
The Chart | NW.js 0.12.3 | Electron 0.34.1 | Project inception | 2011 | 2014 | Sponsor | Intel | GitHub | Platform Support | Mac, Linux & Windows | Browser Runtime | Chromium | libchromiumcontent | Layout Engine | Blink / WebKit 537 | WebKit 537 | JavaScript Engine | V8 | Node.js Engine | io.js v1.2.0 | io.js v? | ES6/2015 Support | Yes (all from V8 v4.1) | Yes (all from V8 v4.4) | Chrome-Equivalent Version | 41 | 44 | Development Model | Open Source | Licensing | MIT License | Entry Point | HTML or JavaScript5 | JavaScript | Bare Distribution Size | 75MB – 100MB4 (30MB – 34MB zipped) | To confirm. Anybody ? | Chrome Apps Support | Yes (in alpha) | No | Support of chrome.* APIs | Yes (in alpha) | No | Adobe Flash Support | Full NPAPI Plugin | Pepper Plugin | Mac App Store Support | Yes | Windows App Store Support | Yes | ? | Support for Windows XP | Yes | No | Source Code Protection | V8 Snapshot1 | ASAR Archive Support2 | Auto-update | Mac/Linux/Win (module) | Mac/Win (thruSquirrel) | Kiosk Mode | Partial (Buggy on Mac6) | Windows Installer | Through nw-builder | Yes (external module) | html5test.com Score3 | 515 | 520 | BrowserMark 2.1 Score3 | 5294 | 5643 | Octane 2.0 Score3 | 27619 | 28346 | GitHub Trends | | | Open Codecs/Containers | Vorbis, Theora, Opus, VP8, VP9, PCM, Ogg, WebM, WAV | Licensed Codecs: MP3, MP4, H.264, AAC | Yes (with some effort) | Yes |
1. This results in a 30% performance hit. It is unclear if it is supported in version 0.13. 2. This is a very weak protection. It’s basically a TAR archive of all the project files. 3. On a MacBook Pro Retina running Mac OS X.5.5 (Yosemite). Higher is better. 4. Unzipped. Depending on platform and architecture. See details in Jared’s comment below. 5. This can be done by using the “node-main” instruction in the package.json file or (in version 0.13 and above) through the Chrome Apps manifest file. 6. Kiosk mode is enabled upstream by Chromium. If you would like the Chromium team to improve kiosk mode support on Mac, please vote for it.
|