6

I have recently started studying Google Web Toolkit. I have went through some walkthroughs, and I think I understand the basics and the idea. However, I have some questions on the overall architecture and design of the applications.

Let's start with the GUI. I want to build a "common" web application, where the user first sees a login page. After successful login, the user is redirected to some kind of index page and a menu is added. I created a new LoginComposite for the login page, and tried to design a nice looking HTML table using the GWT Designer. However, I find that really hard to do, as you cannot set any individual properties on the individual cells (TDs)? There's no way to specify colspan or rowspan, and I can't set any padding or margin on the cells themselves. In short, I know exactly how I would have written the HTML code, but I can't translate that to the designer. Is that just me?

Also, I am wondering about the best practice for code layout and design. I went through the StockWatcher tutorial, but that's really not a very realistic web application. For example, I would like to know how I should design different forms (should each be in a own class inheriting the Composite-class)? How should I switch between forms (for example, first a list view, then a form for editing a chosen item from the list, then a totally different page)? If I have one Composite for each page, and instantiate them when needed in my EntryPoint, would that mean that the client will download all the JavaScript for all those Composites at page load? Should I stick with only one HTML page, or should I have many?

These are questions not really covered by any GWT tutorial. If anyone know a good example of a "real" web application built using GWT, I would love to see it.

Thanks for your input!

joscarsson
  • 4,789
  • 4
  • 35
  • 43

1 Answers1

4

There are a whole bunch of resources in Google IO talks. For example:

Also, don't expect to be able to edit absolutely everything if you are using the GUI to build your GWT app. Good luck!

Finbarr
  • 31,350
  • 13
  • 63
  • 94
  • 1
    Thanks for the links. The first I/O-talk adressed this quite good, some others did not. But because of the talks I found this: http://code.google.com/webtoolkit/doc/latest/DevGuideMvpActivitiesAndPlaces.html. In there there's a good Hello World-example using EventBus, Places, Activites, Presenter and Views. That seems to be the best way to build a GWT application. I'll give it a try. – joscarsson Jul 10 '11 at 21:40
  • 1
    your link is broken (two additional chars in the end), so I'll pist it again: http://code.google.com/webtoolkit/doc/latest/DevGuideMvpActivitiesAndPlaces.html – Stefan Jul 11 '11 at 09:37
  • :), and I forgott to like your links ;) – Stefan Jul 12 '11 at 07:18
  • All links returns 404. – Jayesh Bhoi Jun 19 '23 at 05:40