Skip to content

Reduce false positive of eslint rule exhaustive-deps improving dependency analysis #33462

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

Open
wants to merge 3 commits into
base: main
Choose a base branch
from

Conversation

seiyab
Copy link

@seiyab seiyab commented Jun 6, 2025

Summary

This false positive is reported at #16265 (comment) and a member confirmed it is a bug #16265 (comment)

How did you test this change?

Added test cases

seiyab added 3 commits June 6, 2025 14:28
Signed-off-by: seiya <20365512+seiyab@users.noreply.github.com>
Signed-off-by: seiya <20365512+seiyab@users.noreply.github.com>
Signed-off-by: seiya <20365512+seiyab@users.noreply.github.com>
Comment on lines -1850 to +1871
* Assuming () means the passed/returned node:
* (props) => (props)
* props.(foo) => (props.foo)
* props.foo.(bar) => (props).foo.bar
* props.foo.bar.(baz) => (props).foo.bar.baz
* Assuming {} means the passed/returned node and multiple "=>" means recursive calls:
* {props} => {props}
* {props}.foo => {props.foo}
* {props}.foo.bar.baz => {props.foo}.bar.baz => {props.foo.bar}.baz => {props.foo.bar.baz}
* props.{foo} => props.{foo}
* props.foo.{bar} => props.foo.{bar}
* {ref}.current => {ref}.current
* {props}.foo() => {props}.foo()
* {foo}.bar.baz=123 => {foo.bar}.baz=123
Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm suspicious of the original comment but not sure enough. Feel free to revert the comment.

@seiyab seiyab changed the title Reduce false positive of eslint rule exhaustive-deps improving dependency analysis in Reduce false positive of eslint rule exhaustive-deps improving dependency analysis Jun 7, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants