Skip to content

Commit f08cdca

Browse files
committedDec 7, 2024·
fix: exclude TemplateLiteral expression from isConstant
1 parent 1d6003c commit f08cdca

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed
 

Diff for: ‎packages/babel-plugin-jsx/src/utils.ts

+1-1
Original file line numberDiff line numberDiff line change
@@ -323,7 +323,7 @@ export const isConstant = (
323323
isConstant((property as any).value)
324324
);
325325
}
326-
if (t.isLiteral(node)) {
326+
if (t.isLiteral(node) && !t.isTemplateLiteral(node)) {
327327
return true;
328328
}
329329
return false;

0 commit comments

Comments
 (0)
Please sign in to comment.