Saturday Nov 23, 2013

Simple & Powerful Chrome App Development!

I attended a Devoxx session by Joe Marini entitled Build Native Apps with HTML5? With Chrome Apps, You Can.

Chrome Apps are not Chrome extensions, but off-line applications that run in the Chrome browser. In the above link I read: "Chrome Apps run offline by default, can access the native device hardware, can run on mobile devices, and leverage features not available to traditional Web apps." Very interesting.

During the session, Joe referred to a very nice Git repo full of Chrome App samples:

I checked out that repo and ended up with a long list of samples, like this:

Now let's open one of the samples above into NetBeans IDE and see what it can do for us.

  1. In the New Project wizard, use the "HTML5 Application with Existing Source" template:

  2. Choose one of the sample applications, e.g., the "camera-capture" application:

  3. You'll find that NetBeans IDE adds a 'nbproject' folder to the application:

  4. In the IDE, this is how the application looks:

  5. And now you can deploy it. Right-click the application and choose Run and then you have a browser application that contains a button that enables a camera in the browser application. Then take a pic!

  6. After that, use all the cool tools in NetBeans IDE, e.g., the JavaScript editor, JavaScript debugger, Chrome browser integration, Android/iOS development tools (e.g., debug JavaScript on the device), Chrome Developer Tools integration, HTML editor, CSS editor, etc etc etc.

    Above, you can see that I have deployed the Chrome app into the Chrome browser. I have enabled the NetBeans plugin in the Chrome browser. So now I can click in the browser and see where the clicked item is defined in the IDE, via the live Browser DOM window, which you can see in the left of the screenshot.

NetBeans IDE 7.4 is a perfect development environment for Chrome Apps! No plugins are needed. Just install NetBeans IDE 7.4 ( and you can take all the steps described above, immediately.


Geertjan Wielenga (@geertjanw) is a Principal Product Manager in the Oracle Developer Tools group living & working in Amsterdam. He is a Java technology enthusiast, evangelist, trainer, speaker, and writer. He blogs here daily.

The focus of this blog is mostly on NetBeans (a development tool primarily for Java programmers), with an occasional reference to NetBeans, and sometimes diverging to topics relating to NetBeans. And then there are days when NetBeans is mentioned, just for a change.


« November 2013 »