To allow developers to build faster web apps with Google's proven tools

Nov 6, 2009 10:08 GMT  ·  By
The Google Closure set of JavaScript tools is designed to allow developers to build faster web apps using standard tools
   The Google Closure set of JavaScript tools is designed to allow developers to build faster web apps using standard tools

Google is all about the web apps and, for Google, web apps means JavaScript. The giant has been a huge backer of the scripting language and has played a big part in making it one of the most popular web technologies today. But, now, it wants to help it become even more popular and allow developers to build faster and more powerful web apps, so it's releasing and open sourcing a set of JavaScript tools and libraries that it uses internally on some of its most popular and resource-intensive apps like Gmail, Docs and Maps.

“Like developers everywhere, Googlers want great web apps to be easier to create, so we've built many tools to help us develop these (and many other) apps. We're happy to announce the open sourcing of these tools, and proud to make them available to the web development community,” Google wrote about the new set of tools.

“Closure Compiler, Closure Library, Closure Templates, and Closure Inspector all started as 20% projects and hundreds of Googlers have contributed thousands of patches. Today, each Closure Tool has grown to be a key part of the JavaScript infrastructure behind web apps at Google,” it added.

The Closure Compiler is a JavaScript optimizer, which is designed to make web apps smaller and faster by doing several modifications to the code. It cuts down dead code and then rewrites the rest with a focus on making it more efficient. It also checks various aspects of the code and warns developers of common mistakes.

The Closure Compiler can be run as a command-line tool, but also from a web app that can be accessed either through the site or with a RESTful API. Google has also released a plugin for Firebug, the popular debugging extension for Firefox, to help with the debugging of the optimized code that can be harder for humans to understand.

Just as interesting is the Closure Library, which aims to be a standard, cross-browser library, something that JavaScript has been badly needing. It provides everything from UI widgets and controls to server communications and data structures. Finally, Google is providing a set of Closure Templates, which it says are more like building blocks, rather than traditional templates, allowing developers to easily create a user interface.