Skip to content

Commit e1dced0

Browse files
committed
Refactor to use @imports
1 parent 41e964e commit e1dced0

File tree

2 files changed

+19
-18
lines changed

2 files changed

+19
-18
lines changed

lib/index.js

Lines changed: 18 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -1,18 +1,22 @@
11
/**
2-
* @typedef {import('estree-jsx').Expression} Expression
3-
* @typedef {import('estree-jsx').Identifier} Identifier
4-
* @typedef {import('estree-jsx').ImportSpecifier} ImportSpecifier
5-
* @typedef {import('estree-jsx').JSXAttribute} JSXAttribute
6-
* @typedef {import('estree-jsx').JSXIdentifier} JSXIdentifier
7-
* @typedef {import('estree-jsx').JSXMemberExpression} JSXMemberExpression
8-
* @typedef {import('estree-jsx').JSXNamespacedName} JSXNamespacedName
9-
* @typedef {import('estree-jsx').Literal} Literal
10-
* @typedef {import('estree-jsx').MemberExpression} MemberExpression
11-
* @typedef {import('estree-jsx').Node} Node
12-
* @typedef {import('estree-jsx').ObjectExpression} ObjectExpression
13-
* @typedef {import('estree-jsx').Property} Property
14-
* @typedef {import('estree-jsx').SpreadElement} SpreadElement
15-
*
2+
* @import {
3+
* Expression,
4+
* Identifier,
5+
* ImportSpecifier,
6+
* JSXAttribute,
7+
* JSXIdentifier,
8+
* JSXMemberExpression,
9+
* JSXNamespacedName,
10+
* Literal,
11+
* MemberExpression,
12+
* Node,
13+
* ObjectExpression,
14+
* Property,
15+
* SpreadElement
16+
* } from 'estree-jsx'
17+
*/
18+
19+
/**
1620
* @typedef {'automatic' | 'classic'} Runtime
1721
* How to transform JSX.
1822
*

test.js

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,5 @@
11
/**
2-
* @typedef {import('estree-jsx').Comment} Comment
3-
* @typedef {import('estree-jsx').Expression} Expression
4-
* @typedef {import('estree-jsx').Program} Program
5-
* @typedef {import('estree-jsx').Node} Node
2+
* @import {Comment, Expression, Program, Node} from 'estree-jsx'
63
*/
74

85
import assert from 'node:assert/strict'

0 commit comments

Comments
 (0)