Conversation
🦋 Changeset detectedLatest commit: 4be897f The changes in this PR will be included in the next version bump. This PR includes changesets to release 14 packages
Not sure what this means? Click here to learn what changesets are. Click here if you're a maintainer who wants to add another changeset to this PR |
Merging this PR will not alter performance
Comparing Footnotes
|
WalkthroughAdds a new assist action Possibly related PRs
Suggested reviewers
🚥 Pre-merge checks | ✅ 2✅ Passed checks (2 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches🧪 Generate unit tests (beta)
Comment |
There was a problem hiding this comment.
Actionable comments posted: 2
🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.
Inline comments:
In @.changeset/wise-beds-grow.md:
- Line 5: Update the changeset sentence to fix grammar and tighten wording:
replace “enums members” with “enum members” and rephrase the line to a concise,
past-tense release note such as "Added the new assist action
`useSortedEnumMembers`, which sorts TypeScript and GraphQL enum members." Ensure
the reference to the assist action `useSortedEnumMembers` remains and the
phrasing follows the 1–3 sentence guideline.
In `@crates/biome_js_analyze/src/assist/source/use_sorted_enum_members.rs`:
- Around line 133-146: The function is_enum_member_list_sorted keeps a
persistent prev key across members with None keys, causing comparisons to span
computed-name boundaries; update is_enum_member_list_sorted so that when
get_value_definition_key(&item) returns None you reset prev to None (treat None
as a group boundary) and only compare/assign prev when the key is Some; this
will align detection with the fixer behavior in sorted_separated_list_by and
prevent false diagnostics/fixes.
🪄 Autofix (Beta)
Fix all unresolved CodeRabbit comments on this PR:
- Push a commit to this branch (recommended)
- Create a new PR with the fixes
ℹ️ Review info
⚙️ Run configuration
Configuration used: Path: .coderabbit.yaml
Review profile: CHILL
Plan: Pro
Run ID: 09a46395-d961-4afd-a919-73f9a7f32b6f
⛔ Files ignored due to path filters (7)
crates/biome_diagnostics_categories/src/categories.rsis excluded by!**/categories.rsand included by**crates/biome_graphql_analyze/tests/specs/source/useSortedEnumMembers/invalid.graphql.snapis excluded by!**/*.snapand included by**crates/biome_graphql_analyze/tests/specs/source/useSortedEnumMembers/valid.graphql.snapis excluded by!**/*.snapand included by**crates/biome_js_analyze/tests/specs/source/useSortedEnumMembers/invalid.ts.snapis excluded by!**/*.snapand included by**crates/biome_js_analyze/tests/specs/source/useSortedEnumMembers/valid.ts.snapis excluded by!**/*.snapand included by**packages/@biomejs/backend-jsonrpc/src/workspace.tsis excluded by!**/backend-jsonrpc/src/workspace.tsand included by**packages/@biomejs/biome/configuration_schema.jsonis excluded by!**/configuration_schema.jsonand included by**
📒 Files selected for processing (10)
.changeset/wise-beds-grow.mdcrates/biome_configuration/src/analyzer/assist/actions.rscrates/biome_graphql_analyze/src/assist/source/use_sorted_enum_members.rscrates/biome_graphql_analyze/tests/specs/source/useSortedEnumMembers/invalid.graphqlcrates/biome_graphql_analyze/tests/specs/source/useSortedEnumMembers/valid.graphqlcrates/biome_js_analyze/src/assist/source/use_sorted_enum_members.rscrates/biome_js_analyze/tests/specs/source/useSortedEnumMembers/invalid.tscrates/biome_js_analyze/tests/specs/source/useSortedEnumMembers/valid.tscrates/biome_rule_options/src/lib.rscrates/biome_rule_options/src/use_sorted_enum_members.rs
Summary
Port sorting enums from several Eslint plugins for Graphql & TS
Related #9137 & #536
Test Plan
unit tests
Docs