feat: eslint rule to remove redundant imports#15
Conversation
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
commit: |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: db7d465809
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
onmax
left a comment
There was a problem hiding this comment.
Reviewed locally and addressed the issues on this branch.
Fixed in 7a3c1c5:
- detect aliased auto-import bindings by local name
- keep type-only auto-import metadata separate from runtime imports
- rebuild import declarations correctly when default imports are kept
- add regression coverage and document the new skillHub.eslint option
Verified with:
- pnpm vitest run test/eslint-no-redundant-import.test.ts test/module-setup.test.ts
- pnpm lint
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 4274878690
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 1eb2b1fe7a
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 4936bff02a
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
Summary
nuxt-skill-hub/eslint-plugin) with ano-redundant-importrule@nuxt/eslintis installed via theeslint:config:addonshookunimportand passes them as ESLint settingsimport { type X }toimport type { X }when applicableBefore:
import { ref, computed } from 'vue'(redundant — already auto-imported)After: removed by
eslint --fixOpt-out:
skillHub: { eslint: false }or'skill-hub/no-redundant-import': 'off'Test plan