-
Notifications
You must be signed in to change notification settings - Fork 28
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
Consider keeping @type
comments single-line if possible
#135
Comments
jsdocSingleLineComment: true will make it multiline only if it has more than one tag, or if it exceeds the max line length.
|
set jsdocSingleLineComment to true will solve your issue |
@hosseinmd that won't solve my issue:
That's why I have it set to |
That's the high-level solution, maybe with an exclude for So it'd look like:
I'm wondering if it might be worth supporting this as an option that takes an array that represents the tags to allow being single-line, with the default being I'm happy to have a go at making a PR implementing this either as it's own new option, or as the default behaviour for |
PR is welcome |
I think jsdocSingleLineComment option should be a enum type, and provide:
Weather should be one line is diffrent in diffrent case. So there should be one option to keep they are This is the only reasone forbid me to using this plugin |
@G-Rath maybe this issue can be closed? |
@tjx666 why do you say that? |
Sorry for that message, lone time no see this issue, but see there is a option jsdocSingleLineComment... |
|
This is much better. But we should discuss options. |
implemented deprecated v1.1.0 |
Currently with
jsdocSingleLineComment
set tofalse
, this:Becomes
Personally, I like having multi-line jsdoc comments for "documentation" comments aka generally anytime it has more than a sole
@
tag; I'm less fussed about things like@private
as they're typically on methods which should be documented anyway, but@types
is very common when working in javascript codebases that are statically checked with TypeScript.This also leads to casts being multi-lined which doesn't look quite right (and might even break the cast):
Would it be possible for this plugin to only force a jsdoc comment to be multiline if it had anything except a single
@
tag?The text was updated successfully, but these errors were encountered: