[Jslib] Including only part of JSlib into XUL app

Pete Collins pete at mozdev.org
Wed Sep 17 09:31:58 EDT 2003

mark bokil wrote:
> I am working on an XUL application and I just need from jslib the IO 
> libraries to keep the file size down. Can I copy just the IO folder into 
> my own content folder for an XUL app and then reference the .JS files? 
> What would I have to do to make this work?

All you would need to do is copy the "io" folder to your project.

Change the io identifier paths in jslib.js to point to where "io" is now 
located and possibly any chrome paths referenced in the io files.


   jslib_io = "chrome://myproject/content/io";

Then use the jslib.js file in your xul.

<script type="application/x-javascript" src="jslib.js" />;

     include (jslib_file);

But over all i bet it's just easier using jslib w/ your project.


Pete Collins

More information about the Jslib mailing list