Skip to content

Instantly share code, notes, and snippets.

@lexander
Created May 31, 2013 16:51
Show Gist options
  • Save lexander/5686289 to your computer and use it in GitHub Desktop.
Save lexander/5686289 to your computer and use it in GitHub Desktop.
Example showing how to attach a property to a module using YUIDoc
Y.Namespace("fooNS");
/**
* A test module with some classes attached to it.
* @module fooModule
*/
/**
* Global configuration for the fooModule
* @property config
* @for fooModule
*/
var config = {};
/**
* A test class.
* @class AClass
* @constructor
* @namespace fooNS
*/
function AClass() {
AClass.superclass.constructor.apply(this, arguments);
}
Y.fooNS.AClass = AClass;
/**
* Another test class.
* @class BClass
* @constructor
* @namespace fooNS
*/
function BClass() {
BClass.superclass.constructor.apply(this, arguments);
}
Y.fooNS.BClass = BClass;
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment