Skip to content

Commit

Permalink
fix(no-wildcard-imports): remove migration for TokenSizeKeys (#255)
Browse files Browse the repository at this point in the history
* fix(no-wildcard-imports): remove migration for TokenSizeKeys

* chore: add changeset
  • Loading branch information
joshblack authored Oct 10, 2024
1 parent bf767c6 commit fd2cb55
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 22 deletions.
5 changes: 5 additions & 0 deletions .changeset/short-garlics-kiss.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
'eslint-plugin-primer-react': patch
---

Update no-wildcard-imports rule to no longer migrate the TokenSizeKeys import
12 changes: 0 additions & 12 deletions src/rules/__tests__/no-wildcard-imports.test.js
Original file line number Diff line number Diff line change
Expand Up @@ -270,18 +270,6 @@ import {type ButtonBaseProps} from '@primer/react/experimental'`,
},
],
},
{
code: `import type {TokenSizeKeys} from '@primer/react/lib-esm/Token/TokenBase'`,
output: `import {type TokenSizeKeys} from '@primer/react'`,
errors: [
{
messageId: 'wildcardMigration',
data: {
wildcardEntrypoint: '@primer/react/lib-esm/Token/TokenBase',
},
},
],
},
{
code: `import type {ItemProps} from '@primer/react/lib-esm/deprecated/ActionList'`,
output: `import {type ActionListItemProps as ItemProps} from '@primer/react/deprecated'`,
Expand Down
10 changes: 0 additions & 10 deletions src/rules/no-wildcard-imports.js
Original file line number Diff line number Diff line change
Expand Up @@ -96,16 +96,6 @@ const wildcardImports = new Map([
},
],
],
[
'@primer/react/lib-esm/Token/TokenBase',
[
{
type: 'type',
name: 'TokenSizeKeys',
from: '@primer/react',
},
],
],
[
'@primer/react/lib-esm/deprecated/ActionList',
[
Expand Down

0 comments on commit fd2cb55

Please sign in to comment.