Chromeless 0.3

A new version of Chromeless is tagged which includes new features and bug fixes. This post will tour some of the more interesting features, while a complete summary is a available in the ChangeLog.

A Gallery Of Applications

Inside the Chromeless tree you’ll find a nonchalant directory named gallery. That directory is a collection of git submodules that point to various applications the community has built on top of Chromeless. If you’re not familiar with git submodules, all you have to do to pull down a copy of Chromeless and all of these projects is:

$ git clone git://github.com/mozilla/chromeless
$ cd chromeless
$ git submodule init
$ git submodule update

Having done that you’ll have the code of these projects locally to inspect, and can run them as you would any Chromeless app. Some interesting projects have already emerged, including:

If you’d like to have an application you’re working on listed in the gallery, you can write an email to the Mozilla Labs group, or send a pull request.

Support for Custom Modules

The primary way which Chromeless exposes its functionality to JavaScript is via modules which expose functions and properties. These modules have increased access to the desktop and to the gecko platform, serving as a bridge to expose functionality to application code.

Previously if developers wanted to include new modules with Chromeless they would have to fork the project. That flow is now much more friendly with explicit support to bundle any number of custom modules along with your application, without having to modify Chromeless itself. This feature is exposed via the appinfo.json, and is explained in the documentation. Also an excruciatingly simple bit of sample code has been added which shows how it works.

Native Code with JSCTypes

Chromeless provides a web rendering environment which is great if you want to leverage web technologies to build an application and interact with services on the web. At some point though, you might want to build features not present in Chromeless that require interaction with native libraries.

JSCTypes is a simple new way for JavaScript to interact with native code that landed in Firefox 4. There’s now an example that shows how you might bundle native code with your Chromeless application. The module inclusion feature mentioned above lets you include libraries and expose features built upon them to your application via a JavaScript API of your design.

And More…

In addition to the higher level features discussed above, there have been several smaller additions and bug fixes that are summarized in the ChangeLog, including a simplified library organization, and the ability to have your application spawn multiple windows.

We now begin work on 0.4, which aims to incrementally improve the existing Chromeless libraries, both their features and organization. Please share your thoughts on this release, feature requests, and code contributions on github and the Mozilla Labs mailing list.