I have a function operation
that takes two arguments str
(a String) and fn
(a Function).
function operation(str, fn){
var temp = {}
temp[str] = fn
return temp
}
Is this acceptable for the @return
description?
@returns {Object} With one key set to str and one value set to fn.
Is this acceptable for the @example
output?
operation("foo", console.log)
// => {"foo": [Function]}
The main reason I ask is because I would like to use this format to test the function within a suite like yamadapc/jsdoctest.