On Monday, September 16, 2013 9:39:41 AM UTC+2, Oliver Krylow wrote: > > Thank you for the clarification! > > I wasn't aware of the different handling of "script-inserted" scripts and > I must admit I misunderstood the async /defer attributes. I was hoping to > get on-demand parsing out of it; control over the point in time the browser > starts parsing a previously downloaded script. >
You could download the script using an XMLHttpRequest (or RequestBuilder, or whatever) and then inject it with the ScriptInjector (either as text, or with the URL, using the pre-load request to warm the browser cache only). With code splitting, you have com.google.gwt.core.client.prefetch already to support that exact use-case. You can also customize how fragments are loaded using a custom AsyncFragmentLoader.LoadingStrategy (you could, for example, embed the fragments in the HTML host page in a way that does not parse them and have the LoadingStrategy load them from here, see http://googlecode.blogspot.fr/2009/09/gmail-for-mobile-html5-series-reducing.html; or maybe load them to into/from HTML5 storage); note that this is an "impl" API though, so it can theoretically change between GWT releases (put differently, we don't guarantee any forward/backward compatibility for ".impl" APIs). -- You received this message because you are subscribed to the Google Groups "Google Web Toolkit" group. To unsubscribe from this group and stop receiving emails from it, send an email to google-web-toolkit+unsubscr...@googlegroups.com. To post to this group, send email to google-web-toolkit@googlegroups.com. Visit this group at http://groups.google.com/group/google-web-toolkit. For more options, visit https://groups.google.com/groups/opt_out.