[Jslib] XPCOM Helpers....

Pete Collins pete at mozdevgroup.com
Fri Mar 30 06:32:26 PST 2007

Daniel Aquino wrote:

> hehe exactly my point!
> I really just wanted to use my component as a central point, but 
> wanted to break up functionality across files...
> If you have libraries that highly depend on one another I'd have to do 
> something ugly like put them all in one huge file or embed lots of 
> logic into my component it self.
> Embedding everything into the component would require everything to be 
> a method of the main central component.  It would de-promote oop style 
> of programming in javascript.  And even if I did mesh all my objects 
> into 1 central xpcom component object... thats highly cluttered and 
> problematic..
> Maybe I don't know what I'm talking about but it doesn't seem right to me.

You can probably do what you are trying to do, perhaps taking in the 
target context and applying the required libs to that context.

But jsLib has libraries that are dependent on other libs. For example 
the file library is dependent on a file base class lib.

This is easily accomplished by having the library load it's base if the 
base is not already loaded.


Pete Collins - Founder, Mozdev Group Inc.
Mozilla Software Development Solutions
tel: 1-719-302-5811
fax: 1-719-302-5813

More information about the Jslib mailing list