On Tue, Dec 1, 2009 at 10:59 PM, Mark A. Ziesemer <[email protected]>wrote: > I'm sorry - I may very well be missing something, but I don't see how > this is at all related (?). What I'm proposing would be somewhat > related to the YAHOO.namespace function > (http://developer.yahoo.com/yui/docs/YAHOO.html), though without being > limited to children of the "YAHOO" global object. Actually, the YAHOO > version and others would be able to utilize the version I'm proposing > within their versions.
If the point is to prevent pollution of global code, the proposed module system solves that more securely since it can prevents 3rd party code from doing anything nasty. There is also a related package system they are discussing: http://wiki.commonjs.org/wiki/Packages I've been burned in the past by bad libraries using this idea, so I'm weary of it admittedly. Peter Michaux wrote an excellent article on the subject here: http://peter.michaux.ca/articles/javascript-namespacing Though I don't agree with his solution of using an underscore naming convention, I believe he does justice in defining the problem.
_______________________________________________ es-discuss mailing list [email protected] https://mail.mozilla.org/listinfo/es-discuss

