Skip to content

Commit 5c59e2e

Browse files
committed
fix: checkIsComponent got wrong result
1 parent 17a0e56 commit 5c59e2e

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

packages/babel-plugin-jsx/src/utils.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,7 @@ const checkIsComponent = (path: NodePath<t.JSXOpeningElement>): boolean => {
4444
return !isFragment(namePath); // For withCtx
4545
}
4646

47-
const tag = (namePath as NodePath<t.JSXIdentifier>).get('name');
47+
const tag = (namePath as NodePath<t.JSXIdentifier>).node.name;
4848

4949
return !htmlTags.includes(tag) && !svgTags.includes(tag);
5050
};

0 commit comments

Comments
 (0)