Allow placeholders in JSXElements when parsing templates (#7583)
This commit is contained in:
committed by
GitHub
parent
840ba187a7
commit
f98dff9189
@@ -64,7 +64,7 @@ function placeholderVisitorHandler(
|
||||
state: MetadataState,
|
||||
) {
|
||||
let name;
|
||||
if (t.isIdentifier(node)) {
|
||||
if (t.isIdentifier(node) || t.isJSXIdentifier(node)) {
|
||||
name = ((node: any): BabelNodeIdentifier).name;
|
||||
} else if (t.isStringLiteral(node)) {
|
||||
name = ((node: any): BabelNodeStringLiteral).value;
|
||||
|
||||
Reference in New Issue
Block a user