Wednesday, March 27, 2013

Re: Pre-load server-side resource before client finishes initializing

You can put the data directly into your index.html (static data) or index.jsp (dynamic data generated by server) and load it through GWT's dictionary class. Obviously you would need to make sure that the browser does not cache index.html/jsp in case you need to update the data.

http://google-web-toolkit.googlecode.com/svn/javadoc/latest/com/google/gwt/i18n/client/Dictionary.html


Alternatively you can (mis)use GWT's i18n Constants. That way your data will be compiled into your GWT app and you need to recompile/redeploy it when you need to update that data:

https://developers.google.com/web-toolkit/doc/latest/DevGuideI18nConstants


-- J.


--
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+unsubscribe@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?hl=en.
For more options, visit https://groups.google.com/groups/opt_out.
 
 

No comments:

Post a Comment