-
-
Notifications
You must be signed in to change notification settings - Fork 2.8k
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
[New] forward-ref-uses-ref
: add rule for checking ref parameter is added
#3667
Conversation
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## master #3667 +/- ##
==========================================
+ Coverage 97.62% 97.76% +0.13%
==========================================
Files 132 136 +4
Lines 9692 9743 +51
Branches 3520 3536 +16
==========================================
+ Hits 9462 9525 +63
+ Misses 230 218 -12 ☔ View full report in Codecov by Sentry. |
b706ee7
to
40e8658
Compare
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.
There’s a few lines that are uncovered; it’d be great to add tests that cover them.
9837ead
to
cc19659
Compare
(there's still some uncovered lines) |
I'll work on this more in January; currently busy with holidays. Will make sure to get the last few lines covered and see if I can figure out why ESLint 6 & 7 are failing. |
cc19659
to
2f921af
Compare
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.
There's still a few uncovered added lines.
@NotWoods they're right in the "files changed" tab - see https://github.com/jsx-eslint/eslint-plugin-react/pull/3667/files#diff-25114be5f5c5bf7d89a5cc5dfb905ca0d6aafda4a7cb7b49d20df89ceea52bf4R72 for an example |
380e32c
to
51d342b
Compare
2f921af
to
890427c
Compare
Rebased; tests are failing. |
ad8d26e
to
900ef1c
Compare
900ef1c
to
ceb73fe
Compare
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.
rebased; LGTM assuming tests pass
Closes #3158
Adds a new rule to require that a second parameter is used with
forwardRef
. Offers suggestions to add the parameter or remove theforwardRef
wrapper.