Skip to content

Commit

Permalink
Tweak eslintrc jsdoc settings
Browse files Browse the repository at this point in the history
  • Loading branch information
spalladino committed Aug 1, 2023
1 parent 0ca873e commit e6eb696
Showing 1 changed file with 9 additions and 4 deletions.
13 changes: 9 additions & 4 deletions yarn-project/foundation/.eslintrc.cjs
Original file line number Diff line number Diff line change
@@ -1,6 +1,12 @@
// See https://typescript-eslint.io/play/#ts=5.1.6&showAST=es&fileType=.ts
const contexts = [
'TSMethodDefinition[accessibility=public]',
'MethodDefinition[accessibility=public]',
// All methods in an interface
'TSInterfaceDeclaration TSMethodSignature',
// All public methods in a class that does not implement an interface
'ClassDeclaration[implements.length=0] MethodDefinition[accessibility=public]',
// TODO: All methods public by default in a class that does not implement an interface
// 'ClassDeclaration[implements.length=0] MethodDefinition[accessibility=undefined][key.type=Identifier]',
// Legacy contexts (needs review)
'TSParameterProperty[accessibility=public]',
'TSPropertySignature',
'PropertySignature',
Expand Down Expand Up @@ -120,8 +126,7 @@ module.exports = {
'jsdoc/require-property': [JSDOC_RULES_LEVEL, { contexts }],
'jsdoc/require-property-description': [JSDOC_RULES_LEVEL, { contexts }],
'jsdoc/require-property-name': [JSDOC_RULES_LEVEL, { contexts }],
'jsdoc/require-returns': [JSDOC_RULES_LEVEL, { contexts }],
'jsdoc/require-returns-description': [JSDOC_RULES_LEVEL, { contexts }],
'jsdoc/require-returns': 'off',
},
ignorePatterns: ['node_modules', 'dest*', 'dist', '*.js', '.eslintrc.cjs'],
};

0 comments on commit e6eb696

Please sign in to comment.