Using Dojo with Closure Compiler and Advanced Optimizations

classic Classic list List threaded Threaded
3 messages Options
Reply | Threaded
Open this post in threaded view
|

Using Dojo with Closure Compiler and Advanced Optimizations

Stephen Chung
This post has NOT been accepted by the mailing list yet.
Hi all,

Sorry if this matter has already been discussed.

I have recently been successful in modifying enough of Dojo in order to use the Closure Compiler at Advanced mode.

For my new project, I have only needed to use a small subset of Dojo, Dijit and Dojox, so I am not sure how generally applicable this is.  However, for my project, I successfully got the Closure Compiler to even eliminate the "dijit" and "dojox" objects, flattening those entire namespaces, as well as all my own namespaces.  Many unused functions in dijit and dojox are also removed by the Compiler.  "dojo" is difficult as there are way too many aliases throughout the source code and it is time consuming to get rid of all of them.  You just need one alias for the Closure Compiler to keep a namespace distinct.

Being a Dojo user for a while now, I would like to write up my experiences and things I have learnt on the way, so that the gurus behind this awesome toolkit can also take a look.  Hopefully, we can start on a path to ultimately make the Dojo toolkit useable with the Closure Compiler.

In general, I find that the Closure Compiler is a fabulous piece of work, but I much prefer the Dojo Toolkit (hate the Closure library) and the neat, concise way that Dojo allows me to write code.  So, my goal is to help bring about the best of both worlds.

My humble question: where/who should I send my document to?

Thanks a lot!

- Stephen
Reply | Threaded
Open this post in threaded view
|

Re: Using Dojo with Closure Compiler and Advanced Optimizations

starmonkey
Stephen,

Not that I have any say whatsoever, but why not just start by posting it here or at least a link to it and host it on a blog or something? I am in the midst of a very large, very complex commercial app in which I am just posting here randomly as it will probably be useful to someone...

-r
Reply | Threaded
Open this post in threaded view
|

Re: Using Dojo with Closure Compiler and Advanced Optimizations

Stephen Chung
This post has NOT been accepted by the mailing list yet.
This post was updated on .
In reply to this post by Stephen Chung
Using the Dojo Toolkit with the Closure Compiler in Advanced Mode

Using the Dojo Toolkit with the Closure Compiler in Advanced Mode

- Stephen