jsdoc-vuejs
jsdoc-vuejs copied to clipboard
Helper functions with jsdoc blocks are not output in the documentation
In the example you have a jsdoc block over a helper function (not a vuejs event). Is that documentation supposed to be generated? The only thing generated for me is what is marked as a @vue-event
but I often have functions in methods:
that I wouldn't classify as an event.
Here are the jsdoc package versions I have installed.
...
"jsdoc": "^3.6.3",
"jsdoc-export-default-interop": "^0.3.1",
"jsdoc-vuejs": "^3.0.4",
"jsdoc-vuex-plugin": "^1.0.0",
...
@vue-event
is used to document events emitted by the component with this.$emit('my-event')
.
Functions in methods
are parsed normally by JSDoc, they should not by documented as events.
@Kocal Thank you. Therein lies my problem. Inside of .vue files the only thing parsed and added to the documentation are @vue-*
tags. No other documentation is generated (e.g. a normal jsdoc method).
Inside Vue file, in Methods section, I only use /** *Description of myFunction *@param {Type} paramX - param description */ myFunction(paramX){ .... }
Instead of using @function, i got my methods well parsed by just giving them a description. The vuejs plugin recognizes and uses the name of each method (defined in code) and that is what i see on html doc.