Thoughts About GWT

I find myself repeating myself when I write AJAX web applications.

First I write back-end code to define and manage my models. Then I write front-end code to do the same. The back-end code is in Python, or Ruby, or sometimes PHP. The front-end code is in JavaScript.

It seems absurd to have to define my models in two distinct languages. Worse, after I’ve done so, I have to write substantial glue code to round-trip changes from browser to server and back again.

Perhaps Google Web Toolkit (GWT) solves this problem for me? I haven’t dug deeply at all, but it seems as though I could simply define everything in Java and then let GWT handle the RPC work for me?

That would certainly be a plus in GWT’s favor. I’m not convinced it’s enough to balance out the two negatives I currently see: (1) you often have to “drop down” to HTML and JavaScript when tackling performance issues, and (2) you still have to use CSS; you still have to worry about cross-browser compatibility.