Skip to content

Instantly share code, notes, and snippets.

@jeromeetienne
Last active August 29, 2015 14:10
Show Gist options
  • Save jeromeetienne/eb6cfe8394144dd6d285 to your computer and use it in GitHub Desktop.
Save jeromeetienne/eb6cfe8394144dd6d285 to your computer and use it in GitHub Desktop.
Description of jsdocFunction API

jsdocFunction

It ensures the jsdoc of your function is respected during execution. Check out the live demo.

API

var newFct = jsdocFunction(yourFct)

An Example

/**
 * add two values
 * @param {Number} value1 value one
 * @param {Number} value2 value two
 * @return {Number} the result
 */
var sub	= jsdocFunction(function(value1, value2){
	return value1 - value2
})
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment