Documentation
ESDoc
Our code should be properly documented. We use ESDoc for these purposes.
Here are examples of how various things should be documented:
/**
* Description for class.
* @extends ParentClass
*/
class MyClass extends ParentClass {
// MyClass Code
}
/**
* Function description.
* @param {String} param1 - description of parameter.
* @example Example of usage.
* @returns {String} What it returns, if anything.
*/
myFunction = (param1) => {
// myFunction Code
}
Building docs
To build and preview docs, run npm run docs
to build them.
They will build into a /docs folder in the root. Open up the index.html to preview your changes.
To publish the docs, we need to run the automation.client.ui.publish.docs
jenkins job (http://automationdocs.lifesizecloudbeta.com).
This pulls master and builds the latest version of the docs.