vscode-docthis icon indicating copy to clipboard operation
vscode-docthis copied to clipboard

Type annotation in JSDoc is redundant in Typescript code. (no-redundant-jsdoc)

Open Simbaclaws opened this issue 4 years ago • 1 comments

Hi there,

When I set IncludeTypes to false inside of the settings of the plugin, the @returns still has type annotation for a "any" object type like so:

/**
 * @returns {*}
 */

Is there a way to remove the {*} part? Since typescript is generating warnings because of this.

Please let me know what I can do to generate proper typescript JSDoc for my code.

Simbaclaws avatar Oct 29 '20 13:10 Simbaclaws

Note that if you type above the function declaration /**, then autocomplete will offer two options:

  1. /** */
  2. /** Document This */`

The first seems to be built-in to VSCode (perhaps the TypeScript extension) and will do pretty much the same thing as Document This but without the unnecessary type info in .ts files

MetRonnie avatar Nov 04 '22 15:11 MetRonnie