Preface from the translator. In a postscript to my
yesterday's blog post, I indicated
that AppJS is not the only tool that allows you to create GUI (graphical user interface) applications using web-like development methods in HTML, CSS and JavaScript using
Node.js. A natural illustration of this postscript is the following translation of the githabb project of
node-webkit . And I will immediately say: I foresee in advance that your open-minded opinion will consider
node-webkit an even more convenient and developed tool than AppJS.
Introduction
node-webkit is an environment for running applications based on Chromium
and Node.js. With
node-webkit, you can create traditional graphics applications using HTML and JavaScript. Also,
node-webkit allows you to call
Node.js modules directly from the DOM and thus provides a new way to create such applications and use web technologies in them.
The node-webkit was created and is being developed at the
Intel Open Source Technology Center.')
Introduction to node-webkit (slides).
Virtues
- Applications are created using modern HTML5, CSS3, JS and WebGL.
- Full support for the Node.js API and other modules created by other developers.
- Call API Node.js without any loss in performance.
- Easy packaging and distribution of applications.
Files to download
Release Notes v0.2.6Build version v0.2.6:
Looking for older versions?Demo applications:
Quick Start Guide
Create
index.html :
<html> <head> <title>Hello World!</title> </head> <body> <h1>Hello World!</h1> Node.js <script>document.write(process.version)</script>. </body> </html>
Create
package.json :
{ "name": "nw-demo", "main": "index.html" }
Pack
index.html and package.json in a ZIP archive, and then rename it
to app.nw : app.nw |
Download the node-webkit assembly for your system and use it to open
the app.nw file: $ ./nw app.nw
Note: in Windows, you can drag
app.nw and drop
it on nw.exe to open it.
Read further information about writing, packaging and launching applications:
More information is provided
in our wiki .
Community
As a mailing list, we use
node-webkit on Google Groups , subscribe using
node-webkit+subscribe@googlegroups.com .
License
The node-webkit is distributed under the MIT License
(see attached LICENSE file).
Afterword translator. So, here is a list of noticeable advantages of
node-webkit compared to the project AppJS, which
I reported yesterday :- A more direct style of accessing the Node.js API: in the example above, node-webkit uses process.version , whereas in AppJS you would have to use node.process.version .
- AppJS does not make sound with the <audio> tag , whereas node-webkit does not have this problem.
- In node-webkit there is support for ZIP-packaging of applications and even docking them into the tail to the engine file. AppJS has (nothing else) like it.
- The node-webkit documentation is more or less detailed ( wiki especially). AppJS documentation is almost completely missing.
- The node-webkit application manifest allows you to limit the minimum and maximum widths of the application window. Means AppJS does not achieve this (at least, so easy).
- node-webkit supports the system tray icon and menu , and AppJS does not (yet) . The same can be said about some other nishtyak ( obtaining file names , menu management , access to the clipboard ).
- As stated on Github, the creation and development of node-webkit comes with some support from Intel.