
I posted the news yesterday about Googles new open source JavaScript tools. I was really excited because Goggle typically deliver high quality stuff and getting access to the tools Google have used for their own state of the art on-line applications like Google Apps, Gmail etc. almost is too good to be true. I have downloaded it and taken the first look into the package. My first impression is very good and I have to admit that I’m impressed with it’s huge size and the way it is all structured. The features available really seams useful and I recommend that any web developer take a look at this new set of tools ASAP! Lets now take a look at Closure and I’ll briefly explain what I have uncovered.
Get access to the library
In order to get the newly released Google Closure Library you need to get it from their subversion repository. Google allow anonymous check out and provide a command for people using a command svn client.
svn checkout http://closure-library.googlecode.com/svn/trunk/ closure-library-read-only
It is pretty simple if you know how to do it but if you never worked with subversion you need to get a client first. There are tons of guides and books on using subversion as it is one of / if not the top source control system available and then it is open source. There are also a lot of free client applications available and some are command line oriented while others provide regular application interfaces or fx. integrate directly into windows explorer. You can find a list of worth using clients here and also get the slik SVN command line client for windows I have used for this article. If you download and install Slik SVN you will find the command line tool in “C:\Program Files\SlikSvn\bin”.As svn put the files it check out in the current folder you should create an environment variable making svn.exe available anywhere.

Open svn.exe in a command line window and you’re ready to check out Closure Library. Type or copy in the command provided above.

To be honest I was VERY surprised with the size of this library being nearly 150 MB and counting nearly 9.000 files! This is massive and not something anyone can get an overview of without investing a significant amount of time. The problem with a library of this size is that it can be hard to dig out the really useful elements but at the same time it may indicate that the library Google just released is a very serious tool that may take JavaScript to the next level. 150 MB of mainly .js and some .html test and demo files is more JavaScript than could ever have imagined!
Huge but highly structured
When you open up the bag of goodies you will find that in the top folder Google put in a file called “all_tests.html”. This is a preconfigured JsUnut test lab that you can fire off to verify that everything is OK before you start using it. This is best practice for large development projects and expected that Google use this. Having it as part of the package Google provide is to me a sign of quality and maturity that makes me feel good – year really a good first sight impression!

If you want to look into the features you can benefit from using I would suggest starting in the \closure\goog\demos\ folder. In here there is a lot of very nice demo pages illustrating how the Closure features can be used. Again this is smells good and there are more than 100 demo pages making me believe we’re well covered in! Let’s look at a few examples:
The index page
Yes Closure is huge but with tools like this it quickly becomes manageable!

goog.editor.Field

Graphics
Drawing graphics using Closure is possible but I’m not sure if generating the data for the tiger is simple
)

Data for the yellow pacman seams resonable simple if I managed to locate it.

ProgressBar

Get started using it
I will try Closure out over the next couple of days and plan to post about my experience working with it soon. If you want to try it out yourself you should fire up the article Google provided to give us all a smooth introduction Finding Your Way around the Closure Library. If you have already some experience with Closure please share this in a comment. Also look at the examples and copy some code from there to get started fast!
Related posts:
- Google Release some of their internal JavaScript goodies Google is now providing to the public some of...
- Top 10 JavaScript Frameworks by Google JavaScript – an indispensable part for developing websites and...
- Dojo Javascript Framework, Take your Web Apps to the Next Level Dojo Toolkit is an open-source JavaScript toolkit useful for...
- 30+ Essential Javascript Framework Supported Navigation Techniques Navigation is key to any web site or blog....
- 35+ Create Amazing Image Effects and Sliders with These Awesome jQuery Plugins JavaScript frameworks like jQuery, prototype (and script.aculo.us), Dojo and...
Submit
More Links
RSS
November 8th, 2009 at 3:55 am
nice post, thank you very much for sharing.
November 8th, 2009 at 8:56 am
I’d love if you did a review focusing on closure’s templating system. Their widgets seem pretty straightforward.
November 8th, 2009 at 1:34 pm
Does it mean that the framework doesn’t support Opera? We know that Google somehow doesn’t really like opera.
November 8th, 2009 at 7:42 pm
Thanks for the nice post! Looks interesting. Hope to get round to check it out myself soon.
November 9th, 2009 at 9:19 am
You can find more details on using Google Closure API with ASP.NET at http://www.bloggingdeveloper.com/post/C-Wrapper-for-Google-Closure-Compiler-Compressing-Javascript-Files-on-the-fly-with-ASPNET-and-Closure-Compiler.aspx.
It features a C# wrapper for the tool.
November 19th, 2009 at 12:52 pm
Hi, great article as an introduction to the Closure library! About a week ago I started a blog with the aim of publishing Google Closure tutorials – thought you and your readers might want to take a look! http://googleclosuretutorials.wordpress.com
November 19th, 2009 at 3:38 pm
I tried Closure but I’m not so surprised like you, in fact I prefer the direct/fast way (old way?) as jQuery.