-
Notifications
You must be signed in to change notification settings - Fork 44
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Enable user to use the plural form of @return
#23
Conversation
According to [@use JSDoc](http://usejsdoc.org/tags-returns.html), `@returns` is the actual tag name, and `@return` is a synonym. Keep the existing default (`@return`), but allow user to specify a preference by setting `g:jsdoc_return_plural` to 1.
Seems like a good idea, especially since they are synonyms: http://usejsdoc.org/tags-returns.html |
It's possible that other synonyms might have support added in the future as well, so with that in mind, the var could be refactored to |
@smt That is a good point. Maybe this is a good place to use dictionaries to logically group them as well. E.g. g:jsdoc_tag_synonyms = {
\ 'return': 'returns',
\ 'description': 'desc',
" etc...
\} To let the user define override defaults For reference here is the full list that have synonyms (from http://usejsdoc.org):
|
Sorry for late response.
I like this idea. |
👍 I can give it a go sometime this week, if nobody else beats me to it. I'm closing this PR, and will reference it in a new PR. |
@smt thx. I'm looking forward to your PR 😄 |
👍 |
@smt Just curious if you still plan on doing this? 😄 |
@ryanoasis I got started on it, but didn't get very far before life got in the way. If you are game, feel free to grab this 😁 |
@smt Totally understand that! Maybe if I remember I will check in in another few weeks 😄 I wouldn't start on any work unless I checked with you (no need to duplicate effort 😃) |
My team prefers (and enforces)
@returns
, so here's a PR of my personal hack to enable a configurable variation of the@return
tag output.The
@return
tag remains the default unless theg:jsdoc_return_plural
option is set to 1.