Thread:Manual talk:Coding conventions/JavaScript/Place for Extensions Objects in JavaScript/reply

As already described in the conventions, no globals other than  and   should be used.

I agree placing it on one of these globals directly is bad.

Extensions providing third-party libraries generally alias those globals in  and use them from there. A similar thing for  makes sense.

As for the structure, I'd recommend this:

Note that some extensions already do this, through. I'd like to keep that separate, though on the other hand, that one already exists and is available today.