File tree 3 files changed +3
-6
lines changed
3 files changed +3
-6
lines changed Original file line number Diff line number Diff line change @@ -224,10 +224,8 @@ export function recmaDocument(options = {}) {
224
224
handleEsm ( child )
225
225
} else if (
226
226
child . type === 'ExpressionStatement' &&
227
- // @ts -expect-error types are wrong: `JSXElement`/`JSXFragment` are
228
- // `Expression`s.
227
+ // @ts -expect-error types are wrong: `JSXFragment` is an `Expression`.
229
228
( child . expression . type === 'JSXFragment' ||
230
- // @ts -expect-error "
231
229
child . expression . type === 'JSXElement' )
232
230
) {
233
231
content = true
@@ -523,7 +521,6 @@ export function recmaDocument(options = {}) {
523
521
]
524
522
}
525
523
526
- // @ts -expect-error: JSXElements are expressions.
527
524
let result = /** @type {Expression } */ ( element )
528
525
529
526
if ( ! hasInternalLayout ) {
@@ -542,6 +539,7 @@ export function recmaDocument(options = {}) {
542
539
543
540
let argument = content || { type : 'Literal' , value : null }
544
541
542
+ // Unwrap a fragment of a single element.
545
543
if (
546
544
argument &&
547
545
// @ts -expect-error: fine.
Original file line number Diff line number Diff line change @@ -77,7 +77,6 @@ export function recmaJsxRewrite(options = {}) {
77
77
enter ( _node ) {
78
78
const node = /** @type {Node } */ ( _node )
79
79
const newScope = /** @type {Scope|undefined } */ (
80
- // @ts -expect-error: periscopic doesn’t support JSX.
81
80
scopeInfo . map . get ( node )
82
81
)
83
82
Original file line number Diff line number Diff line change 46
46
" index.js"
47
47
],
48
48
"dependencies" : {
49
- "@types/estree-jsx" : " ^0 .0.1 " ,
49
+ "@types/estree-jsx" : " ^1 .0.0 " ,
50
50
"@types/mdx" : " ^2.0.0" ,
51
51
"astring" : " ^1.6.0" ,
52
52
"estree-util-build-jsx" : " ^2.0.0" ,
You can’t perform that action at this time.
0 commit comments