Skip to content

[require-jsdoc] Question: Is it possible to not require jsdoc if the interface or abstraction already provide jsdoc? #696

@Shinigami92

Description

@Shinigami92

Motivation

image

Current behavior

I currently have setup following rule:

    'jsdoc/require-jsdoc': [
      'warn',
      {
        contexts: [
          'ClassDeclaration',
          'ClassProperty:not([accessibility=/(private|protected)/])',
          'ExportNamedDeclaration:has(VariableDeclaration)',
          'FunctionExpression',
          'MethodDefinition:not([accessibility=/(private|protected)/]) > FunctionExpression',
          'TSEnumDeclaration',
          'TSInterfaceDeclaration',
          'TSMethodSignature',
          // 'TSPropertySignature',
          'TSTypeAliasDeclaration'
        ]
      }
    ]

Sadly I don't see an option to prevent the need of writing jsdoc if the implemented interface or abstract class already provides JSDoc.
And I don't want to duplicate the JSDoc everywhere.

Desired behavior

Any kind of possibility to not warn when the function that is implemented already provides jsdoc, without the need of eslint-disable-next-line

Metadata

Metadata

Assignees

No one assigned

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions