Wednesday, August 5, 2020

GWT permutations / sourceMaps / code splitting

Hi,

I've been compiling my GWT app with both native and emulated stackMode or a long time:
<set-property name="compiler.stackMode" value="native,emulated"/>

I serve by default the native permutations but I can also request the emulated permutations:
<meta name="gwt:property" content="compiler.stackMode=<%=my_var%>">

It's particularly useful to generate stacktrace with exact line number and we use it extensively!

I'd like now to enhance the emulated permutations and embed the sourceMaps something like that:

<set-property name="compiler.stackMode" value="native,emulated"/>
<set-property name="compiler.useSourceMaps" value="true">
<any>
<when-property-is name="compiler.stackMode" value="emulated" />
</any>
</set-property>
<set-configuration-property name="includeSourceMapUrl" value="/extra/ccclight/symbolMaps/__HASH___sourceMap__FRAGMENT__.json"/>

But our GWT app is huge and we use GWT Code splitting.
The issue with the above approach is the sourceMaps not being really useful because most of the code is not mapped properly!

Screen Shot 2020-08-06 at 4.12.10 PM.png



But if I add the collapse-all-properties tag then the sourceMaps works properly and all lines are properly mapped and I can add breakpoint!
But I want to use collapse-all-properties only when compiling the emulated permutations, something like that:

<collapse-all-properties>
<any>
<when-property-is name="compiler.stackMode" value="emulated" />
</any>
</collapse-all-properties>

But GWT does not support it!

[INFO]       [ERROR] Line 69: Child element 'any' is not allowed

So can we either fix the source mapping when using Code Splitting or can we support condition tags on the collapse-all-properties tag?

Thank you

--
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+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/google-web-toolkit/e69d5fa3-eb9f-48d4-a4d2-b5331e44de6eo%40googlegroups.com.

No comments:

Post a Comment