Multiple JS-libraray inclusions

2007-08-17 Thread Jan Kriesten

Hi,

should there be a common way to include css/libraries?

Currently, every component dependend on e.g. PrototypeJS is adding it to the
Page. Different components do this and if being on the same page, in the end
there may be 2 or 3 inclusions of the same lib from different locations.

Maybe there could be a registry or a common ID for libs using their originating
source-url (like namespaces) to minimize such things?

Common/known IDs could be listed in the Wiki then (and referenced from the
Javadoc)!?

Just thinking... --- Jan.

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Multiple JS-libraray inclusions

2007-08-17 Thread Jan Kriesten

hi igor,

 while this might help one-file js libs like prototype how is it going to
 work for libs that load other files themselves?
 you can have the same dojo version in two different components, but they can
 include different modules...

yes - and? as long as all dojo-files are included, both components can load
there modules from the same contribution. in most cases it's very unlikely, that
the distributions are stripped down to only the needed items.

that's also just the point, having some sort of common id for libraries should
assure all dependend files are available at that location.

--- jan.


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Multiple JS-libraray inclusions

2007-08-17 Thread Igor Vaynberg
i just downloaded dojo 0.9beta

it runs in at 16mb

if all i want is to build a modal dialog using dojo i do not want to
distribute a 16mb jar. given that is uncompressed and can probably shrink
down to less then a third, still it is gigantic.

so if i can strip out all i do not use and shrink my jar to a few KB you bet
i will do that instead.

-igor


On 8/17/07, Jan Kriesten [EMAIL PROTECTED] wrote:


 hi igor,

  if anyone has any better solutions im all ears. the problem is that the
  components are encapsulated, so you can never count on any of them to
  include the full version of any lib they depend on. and today
 unfortunately
  these libs are so big that they come with multiple files - and on top of
  that have all these dynamic loaders.

 i know that maintaining such a lib isn't really doable.

 but why shouldn't libraries actually deliver the whole packages with them
 and
 set a common id on it - and it's wicket to decide which location came
 first?
 it's no problem of data-redundancy in the jars, but contributing more than
 once
 to the browser.

 --- jan.



 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]




Re: Multiple JS-libraray inclusions

2007-08-17 Thread Igor Vaynberg
On 8/17/07, Eelco Hillenius [EMAIL PROTECTED] wrote:

  there are just too many holes in this idea for us to implement it
 properly
  where it Hust Works. we can implement it half way and spend a lot of
 time
  answering questions as to why something doesnt work sometimes based on
 what
  components you have in your page or not.

 So let's just stop thinking about it then.


you know damn well thats not what i meant! jackass. the current  global id
idea is simply not enough to fix much of anything.

-igor


Eelco

 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]