-
-
Notifications
You must be signed in to change notification settings - Fork 475
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
fix(lint/useJsxKeyInIterable): don't trigger useJsxKeyInIterable
when iterating on non-jsx things
#2667
Merged
ematipico
merged 1 commit into
biomejs:main
from
dyc3:05-01-fix_lint_don_t_trigger_usejsxkeyiniterable_when_iterating_on_non-jsx_things
May 3, 2024
Merged
Conversation
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
github-actions
bot
added
A-Linter
Area: linter
L-JavaScript
Language: JavaScript and super languages
labels
May 1, 2024
dyc3
changed the title
fix(lint): don't trigger
fix(lint/useJsxKeyInIterable): don't trigger May 1, 2024
useJsxKeyInIterable
when iterating on non-jsx thingsuseJsxKeyInIterable
when iterating on non-jsx things
anonrig
approved these changes
May 1, 2024
dyc3
force-pushed
the
05-01-fix_lint_don_t_trigger_usejsxkeyiniterable_when_iterating_on_non-jsx_things
branch
from
May 1, 2024 15:39
0f86ef9
to
25e483a
Compare
CodSpeed Performance ReportMerging #2667 will not alter performanceComparing Summary
|
dyc3
force-pushed
the
05-01-fix_lint_don_t_trigger_usejsxkeyiniterable_when_iterating_on_non-jsx_things
branch
from
May 1, 2024 17:16
25e483a
to
d524940
Compare
crates/biome_js_analyze/src/lint/correctness/use_jsx_key_in_iterable.rs
Outdated
Show resolved
Hide resolved
1 task
dyc3
force-pushed
the
05-01-fix_lint_don_t_trigger_usejsxkeyiniterable_when_iterating_on_non-jsx_things
branch
from
May 2, 2024 16:40
d524940
to
5f72d5f
Compare
dyc3
force-pushed
the
05-01-fix_lint_don_t_trigger_usejsxkeyiniterable_when_iterating_on_non-jsx_things
branch
from
May 2, 2024 16:42
5f72d5f
to
65a06f2
Compare
dyc3
force-pushed
the
05-01-fix_lint_don_t_trigger_usejsxkeyiniterable_when_iterating_on_non-jsx_things
branch
from
May 3, 2024 11:53
65a06f2
to
bbecf2b
Compare
ematipico
approved these changes
May 3, 2024
dyc3
force-pushed
the
05-01-fix_lint_don_t_trigger_usejsxkeyiniterable_when_iterating_on_non-jsx_things
branch
from
May 3, 2024 12:54
bbecf2b
to
644a6ed
Compare
I've moved the conditional expression check to another branch that I have locally, and I'll post the PR for that once this is merged. |
Feel free to leave possible comments @vohoanglong0107, in case there's something missing |
dyc3
deleted the
05-01-fix_lint_don_t_trigger_usejsxkeyiniterable_when_iterating_on_non-jsx_things
branch
May 3, 2024 19:11
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Labels
A-Changelog
Area: changelog
A-Linter
Area: linter
L-JavaScript
Language: JavaScript and super languages
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Summary
This aims to resolve some of the bugs in #2590. It's intentionally small in scope since this is my first PR here, so hopefully it will be easier to review.
It fixes cases where expressions like this would erroneously trigger the
useJsxKeyInIterable
lint:related to: #2590
Test Plan
I added tests.
cargo test -p biome_js_analyze use_jsx_key_in_iterable