-
Notifications
You must be signed in to change notification settings - Fork 305
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
chore: Move jsdocs to interfaces (#1356)
Our current eslint setup was enforcing all `public` methods in _classes_ to have a jsdoc, but not interfaces. As a result, most of our interfaces (where we want to have docs the most) were undocumented, and the classes that implement them carried the documentation instead. This PR changes the eslint config so we enforce all interface methods to have documentation. All classes that implement them automatically inherit their docs (in vscode intellisense and in typedoc), so we don't need to repeat the docs there and can clean those up. Unfortunately, `require-jsdoc` cannot detect this automatically (see gajus/eslint-plugin-jsdoc#768), so we tweak the config so that jsdoc is not required for methods of classes that implement an interface (not perfect, but good enough). This new esquery filter required bumping the version of tslint. Another issue with our config is that methods that are public by default (ie without an accessibility modifier) do not have jsdoc enforced. I tried enabling that but got 148 missing docs - so I'll leave that out for now, and is commented in the eslintrc file.
- Loading branch information
1 parent
0793d4a
commit 7f7519d
Showing
40 changed files
with
698 additions
and
580 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.