O'Reilly logo

Essential GWT: Building for the Web with Google Web Toolkit 2 by Federico Kereki

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

8. Mixing in JavaScript

JavaScript is to GWT what assembly language is to classic compilers, and although you should be careful, mixing JavaScript in with your Java code can help. For example, you can attain better performance, or achieve otherwise hard-to-get results, including getting data from remote servers bypassing the Same Origin Policy we covered in previous chapters.

There are some circumstances when you will need to add some JavaScript to your application, and GWT provides a solution for this kind of situation. The GWT developers frequently use this to get low-level access to browser aspects, but there are other possible usages, such as taking advantage of prewritten JavaScript routines and libraries, using JSON (an alternative to XML) ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required