[Project_owners] global namespace conflicts?
Eric H. Jung
grimholtz at yahoo.com
Tue Jun 6 15:44:34 EDT 2006
Why is it that the root of all Phil's question come down to SeaMonkey? :)
----- Original Message ----
From: Neil <neil at parkwaycc.co.uk>
To: project_owners at mozdev.org
Sent: Tuesday, June 6, 2006 4:19:18 AM
Subject: Re: [Project_owners] global namespace conflicts?
Philip Chee wrote:
>On Fri, 2 Jun 2006 16:07:32 -0700 (PDT), Neil wrote:
>>Eric H. Jung wrote:
>>>Can variables defined in files in the components/ directory of a XPI conflict
>>Each JS component has its own script global object, so they don't conflict either with each other or with DOM windows.
>The Greasemonkey component uses mozIJSSubscriptLoader to load scripts from the extension part of Greasmonkey. Why would they do it this way?
Writing them as individual components would of course give each file a
separate global namespace. While it's possible to do this, it's harder
for the developer as the components can only be created via the
component manager. Nor can the components share utility functions. As an
aside, it also means that even if it could be made to work in SeaMonkey
1.0.x it would have to be installed globally.
Project_owners mailing list
Project_owners at mozdev.org
More information about the Project_owners