Created
June 2, 2012 13:06
-
-
Save wfaler/2858321 to your computer and use it in GitHub Desktop.
namespacingWithoutPollutingGlobalNamespace.coffee
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# setting 'exports' as alias to global namespace | |
exports = this | |
# creating an empty object to act as a namespace for classes in this file | |
exports.ext = {} | |
# GreeterPanel is a previously defined CoffeeScript class | |
# namespacing and exposing GreeterPanel globally in the ext.GreeterPanel namespace | |
exports.ext.GreeterPanel = GreeterPanel |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment