"[This] is not a technical problem," he wrote. "It's a matter of people getting together and making a decision to step forward and start building up something bigger and cooler together."
The call was answered.
One month later, we had converged on a specification for module systems and interoperable modules. Now, there are over a dozen compliant implementations of CommonJS module loaders, and hundreds of compliant modules.
CommonJS is a growing collection of standards, including
- Binary strings and buffers
- Charset encodings
- Binary, buffered, and textual input and output (io) streams
- System process arguments, environment, and streams
- File system interface
- Socket streams
- Unit test assertions, running, and reporting
- Web server gateway interface, JSGI
- Local and remote packages and package management
So far, CommonJS has converged on specifications for modules (1.1), a system module (1.0), and a unit testing API (1.0). The intent is to drive for a binary API next; both ECMA TC39 (the technical committee responsible for ECMAScript) and the W3C (the standards body responsible for browser standards) are considering a joint pursuit.
And the best part is that it's real. At jsconf.eu, several the CommonJS founder projects showcased CommonJS compliant module systems, a couple projects announced they were using CommonJS, and many others expressed interest in bringing CommonJS to their platforms.
Narwhal supports CommonJS modules and has prototype implementations of IO, file-system support, and binary data. Narwhal also comes with a wealth of standard library modules collected and ported from every end of the Web for everything from command line option parsing to secure hashing. Narwhal works out of the box and includes a package manager, "tusk," that gives you instant access to literally dozens of installable packages. In all seriousness, the catalog is growing quickly because making a package is as simple as adding a package.json file to the root of a project on Github and as flexible as putting a Zip archive with a package.json anywhere on the Web.
And there's more…so much more to come.
- The presentations at SpeakerRate
- The presentations directly on SlideShare
- Tom Hughes-Croucher's article on the Yahoo! Developer Network Blog
- Get a glimpse of jsconf.eu through the lens of Mathias Meyer
If you want to learn more about CommonJS, the best place to start is the Wiki. Check out the Status to see what's going on right now. I'm sure everyone here knows something they would like to see done right—