I'm trying to make some sense from that Elemental feature. But I'm definitely missing something. On 2.5 main page there is a link to a brief article about Elemental which really does not add much. GWT team is notoriously bad on documentation side and it's not getting any better. Just please don't tell me to shut up and use something else. It's impossible to see the big picture without some background information, like what was missing before, what real purpose of the feature is. It's very nice that we can now call some latest API but what about the more trivial stuff that say UiBinder was in charge so far? Or maybe it is not about UI but more about better hiding JSO types? Or something totally different at all?
It's not any better with all other features in fact, but right now my gripe is about Elemental.I looked at the Collide project code. They reference elemental.* packages all over the place and elemental classes carry copyright statement from 2010. So is it new or just recently opened by Google?
Thank you very much Thomas for the expanded answer. (I'm somewhat worried about GWT as a "bus factor" looks close to one).I understand what you say, but my question is more of an Elemental consumer nature. I mean it's definitely a big time saver for the GWT team to generate semi-magically all java wrappers for all existing and forthcoming features, it makes keeping GWT up to date much easier, but from GWT consumer point of view (i.e. all developers using GWT not developing it) it buys what? It's definitely better to have 5 permutations (e.g. per locale) instead of 30 but that's just compilation time, so it's nice but not critical. Also supporting old browsers still will add a few extra permutations anyway.
The unit-test factor is probably important if you have them - I'm so far from them in my adventure, that I cannot appreciate this.Removing all extra layers. Hmm... If we get too close to DOM and JavaScript then GWT advantage may be questioned as well. Java being a statically typed language is a double-edged sword. Those programming closer to the metal in fact prefer to stay behind extra layers of abstractions be it jQuery, CoffeeScript or Backbone.js.
Again I'm not questioning Elemental utility greatness, but so far it looks to be much more important to GWT "internally" than to the rest of us, mere GWT consumers.
Not having permutations "per UA" is not only a compile-time thing, it also means you don't have to "sniff" the UA at runtime, so there's no risk of false-positives or false-negatives (http://code.google.com/p/google-web-toolkit/issues/detail?id=2938, http://code.google.com/p/google-web-toolkit/issues/detail?id=5278, http://code.google.com/p/google-web-toolkit/issues/detail?id=6665) and supporting a new browser (https://groups.google.com/d/topic/es-operating-system/8oWtRZnDK_w/discussion) comes for free.
Again I'm not questioning Elemental utility greatness, but so far it looks to be much more important to GWT "internally" than to the rest of us, mere GWT consumers.Everyone has different needs.
On Tuesday, July 10, 2012 9:47:56 AM UTC-4, Thomas Broyer wrote:
Not having permutations "per UA" is not only a compile-time thing, it also means you don't have to "sniff" the UA at runtime, so there's no risk of false-positives or false-negatives (http://code.google.com/p/google-web-toolkit/issues/detail?id=2938, http://code.google.com/p/google-web-toolkit/issues/detail?id=5278, http://code.google.com/p/google-web-toolkit/issues/detail?id=6665) and supporting a new browser (https://groups.google.com/d/topic/es-operating-system/8oWtRZnDK_w/discussion) comes for free.The goal is to only have a single permutation? I thought the multiple permutation system of GWT was only good (though admittedly I have been burned by IE9 and 10). Isn't it preferable to not send -moz-linear-gradient(...) to Chrome and -webkit-linear-gradient(...) to Firefox? (Same with mozIndexedDB vs webkitIndexedDB.) I thought this made the code smaller and better tailored than the "this or this or this" style of coding.
Also, assuming I go this route, how do I tell GWT to just do one permutation without UA concerns? I've been working on an app that I was originally only targeting webkit for (thus <set-property name="user.agent" value="safari"/>), but nothing in it should necessarily have broken in Firefox (besides the WebSQL stuff). So I decided to point Firefox to it, and immediately got an alert saying Firefox wasn't supported, despite the app working well enough. Obviously it was easy to fix by adding gecko1_8 to set-property, but how do I create the one permutation to rule them all that doesn't complain?
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
> (just like everyone else doing web dev out there, in JS, CoffeeScript, Dart, etc.)
TLDR: There are many of us out here, I suspect, for whom this is exactly
what we do not want.
Elemental sounds cool, but I'm glad it's optional. I hope that stays
the case, and that the permuted-compile use case stays well-supported
for the foreseeable future.