On 23.12.2009, at 21:22, Dan Allen wrote:
On Wed, Dec 23, 2009 at 3:17 PM, Lincoln Baxter, III
<lincolnbaxter(a)gmail.com
> wrote:
Then there's the lovely version issue, when each lib depends on a
different jquery... oops; ) that one shouldn't happen too much, but
Its worth considering... might be easy just to say "you're on your
own"
Well, in a sense it would be like a Maven dependency in that you
have to specify a version range of compatibility. If the the page
attempts to load different versions, where one is not in the range
of accepted versions of the other, it would throw some sort of
compatibility exception (otherwise, you just get unexpected behavior
in the page). I'm speaking fairly high level here, but certainly
worth considering if the goal is the really make sure we support
mixing and matching components.
While it would be great to have jsf automatically resolve duplicates/
versions, I think sometimes the developers has to get involved, so
first of all it should be possible to map resource-requests to other
resources, so that a user (=developer) could say (.*)jquery(.*).js
maps to lets say a jquery-min-1.2.13.js resource in some other jar or
war.
(This could even be used to replace images of components with one
line, if you allow for references from the matches on the source-
regexp in the target-exp)
While it is possible to do that on your own, I think that could be a
valuable addition to the specs.
Concerning version issues, I don't think we should come up with a
solution (which would probably involve versionnamespacing the included
scripts and the calls to it... ugly!) but as suggested just say
"you're on your own".
Imre