On Fri, Mar 13, 2009 at 8:36 AM, lkcl <[email protected]> wrote:
> i have a post-processing compile step in which i just go "ok, let's > assume everything was globally imported" and make sure that the first > thing an app does is dynamically load aaabsolutely everything (in the > right order of course). > Ok, so all this is buying you is savings on the total size of scripts at the expense of dramatically increasing the number of round trips for app startup, which is actually the opposite of what runAsync is trying to do -- there the goal is to get the app up and running as quickly as possible, and let code needed later (or not at all) by the user get loaded later. The number of HTTP round trips is a huge factor in the perceived performance of a web app. I think a better way to approach this would be to have a server component that dynamically builds the response from small pieces so you get the entire thing in one HTTP request but shared code can be shared between all the permutations. Ie, for permutation n it knows modules A, C, D, G are required so it simply reads those from storage and prepends them (in the right order) to the permutation-specific file and sends it to the browser in response to the request. -- John A. Tamplin Software Engineer (GWT), Google --~--~---------~--~----~------------~-------~--~----~ http://groups.google.com/group/Google-Web-Toolkit-Contributors -~----------~----~----~----~------~----~------~--~---
