-
Notifications
You must be signed in to change notification settings - Fork 279
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
test: Enable a few good typescript-eslint rules #969
Conversation
Codecov Report
@@ Coverage Diff @@
## main #969 +/- ##
==========================================
+ Coverage 63.23% 63.30% +0.07%
==========================================
Files 62 62
Lines 7918 7906 -12
Branches 1837 1829 -8
==========================================
- Hits 5007 5005 -2
+ Misses 2790 2781 -9
+ Partials 121 120 -1
Continue to review full report at Codecov.
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks amazing -- I love these kinds of changes! Thanks for doing this hard work to improve the codebase now and in the future. Do we need to log an issue so we go back and clean up any remaining warnings and change the mode from warning to error?
Hmm we can; the thing is, a lot of the things we have set to |
Description
This PR enables a few good typescript-eslint rules:
@typescript-eslint/no-base-to-string
catches a bunch of places where we try to stringify things that would just show up as"[object Object]"
; I didn't have the bandwidth in this PR to fix these so I just set this rule to"warning"
, but they are all genuine bugs as far as I can tell@typescript-eslint/no-confusing-void-expression
might be a bit more of a stylistic thing, but I think it's pretty good for clarity@typescript-eslint/no-unnecessary-boolean-literal-compare
didn't surface much, but it seems like a good thing to have enabled@typescript-eslint/no-unnecessary-condition
surfaced a bunch of bugs and also a bunch of things that are due to us using the type system poorly; again I didn't have the bandwidth here to fix all these so I just made it a"warning"
, but this is very good to have enabled@typescript-eslint/prefer-ts-expect-error
doesn't actually affect anything currently, but it is quite good so I'm enabling it proactivelyChecklist
diagrams/
folder