Hi

I know it's an old thread but I used few hours to quickly implement a 
linker and special entry point class that uses script tags from gwt.xml 
files and injects them automatically using ScriptInjector. There are few 
changes required in EntryPoint classes but they are not that intrusive.

Could you tell me if such approach is sensible? Do you see any problems it 
could cause (except difference in performance - scripts have to be loaded 
one after another instead of almost concurrently).

Link to repo: https://github.com/metteo/gwt-si

Greg

On Monday, November 12, 2012 at 5:54:57 PM UTC+1, Thomas Broyer wrote:
>
>
>
> On Monday, November 12, 2012 4:55:58 PM UTC+1, googelybear wrote:
>>
>> I have the same error when running the code server and this limitation 
>> effectively prevents me from using superdevmode, as in my case the problem 
>> is with an external library that I include which then uses the <script> tag 
>> in its own module xml.
>> Also not being able to use <script> in the module xml 
>> breaks encapsulation of modules, as I know have to include *all* scripts 
>> from *all* libraries in *my* host page (for me that's implementation 
>> details that I don't care about) .
>>
>
> There's ScriptInjector 
> <http://google-web-toolkit.googlecode.com/svn/javadoc/latest/com/google/gwt/core/client/ScriptInjector.html>
>  
> to encapsulate loading within the module's code.
>  
>
>> I know superdevmode is still experimental and seriously hope that this 
>> will be fixed. In the meantime does anyone have an idea how to work around 
>> this? Besides manually patching a 3rd party library...
>>
>
> In your module that enables the SuperDevMode hooks, add the 
> failIfScriptTag configuration property and add an entry-point that uses 
> ScriptInjector to load the 3rd-party scripts. The 2 entry points (from your 
> app, inherited GWT module, and from the SuperDevMode-specific module) will 
> both be executed; beware though that onModuleLoad will be called *before* 
> the scripts are loaded, so your code that depends on them has to wait a 
> bit… There are a couple ways to workaround this if really needed (but it's 
> a bit more "invasive" for your app; that being said, xsiframe is the 
> future, and might becomes the default at some point, so better be prepared 
> –and update your 3rd-party libs–)
>

-- 
You received this message because you are subscribed to the Google Groups "GWT 
Users" 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/d/optout.

Reply via email to