-
-
Notifications
You must be signed in to change notification settings - Fork 724
fix(linter): useImportExtensions
handles queries and hashes
#7640
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
Conversation
🦋 Changeset detectedLatest commit: 6888c50 The changes in this PR will be included in the next version bump. This PR includes changesets to release 13 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 |
useImportExtensions
handles queries and hashes
WalkthroughAdds a patch changeset documenting a fix to the useImportExtensions rule: imports ending with a query or hash are no longer flagged. The lint implementation now extracts and strips query/hash suffixes from the last path segment, mutates the detected extension accordingly, and withholds extension suggestions when such a suffix is present. Construction of the result sets module_name_token directly. Test fixtures add a CSS file and a valid import case using ./sub/theme.css?inline to ensure no diagnostics are emitted. Possibly related PRs
Suggested labels
Suggested reviewers
Pre-merge checks and finishing touches❌ Failed checks (1 warning)
✅ Passed checks (4 passed)
✨ Finishing touches
🧪 Generate unit tests
📜 Recent review detailsConfiguration used: Path: .coderabbit.yaml Review profile: CHILL Plan: Pro ⛔ Files ignored due to path filters (1)
📒 Files selected for processing (4)
🧰 Additional context used📓 Path-based instructions (6)crates/biome_*_{syntax,parser,formatter,analyze,factory,semantic}/**📄 CodeRabbit inference engine (CLAUDE.md)
Files:
crates/biome_*/**📄 CodeRabbit inference engine (CLAUDE.md)
Files:
**/tests/**📄 CodeRabbit inference engine (CLAUDE.md)
Files:
.changeset/**/*.md📄 CodeRabbit inference engine (CONTRIBUTING.md)
Files:
**/*.{rs,toml}📄 CodeRabbit inference engine (CONTRIBUTING.md)
Files:
**/*.rs📄 CodeRabbit inference engine (CONTRIBUTING.md)
Files:
🧬 Code graph analysis (1)crates/biome_js_analyze/src/lint/correctness/use_import_extensions.rs (1)
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (24)
🔇 Additional comments (7)
Comment |
CodSpeed Performance ReportMerging #7640 will not alter performanceComparing Summary
Footnotes |
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.
🙌
Summary
Fixed #7638:
useImportExtensions
no longer emits diagnostics on valid import paths that end with a query or hash.Example
Test Plan
Test case added. Existing test cases still pass.
Docs
N/A