@immense/vue-pom-generator 1.0.55 → 1.0.56

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.mjs CHANGED
@@ -1224,6 +1224,12 @@ function nodeHandlerAttributeInfo(node) {
1224
1224
  const n = node2;
1225
1225
  return typeof n.callee === "object" && n.callee !== null && Array.isArray(n.arguments);
1226
1226
  };
1227
+ const isAwaitExpressionNode = (node2) => {
1228
+ if (!isNodeType(node2, "AwaitExpression"))
1229
+ return false;
1230
+ const n = node2;
1231
+ return typeof n.argument === "object" && n.argument !== null;
1232
+ };
1227
1233
  const isAssignmentExpressionNode = (node2) => {
1228
1234
  if (!isNodeType(node2, "AssignmentExpression"))
1229
1235
  return false;
@@ -1430,14 +1436,15 @@ function nodeHandlerAttributeInfo(node) {
1430
1436
  if (isArrowFunctionExpressionNode(expr)) {
1431
1437
  const body = expr.body;
1432
1438
  const tryFromCallExpression = (call) => {
1433
- if (!isCallExpressionNode(call)) {
1439
+ const resolvedCall = isAwaitExpressionNode(call) ? call.argument : call;
1440
+ if (!isCallExpressionNode(resolvedCall)) {
1434
1441
  return null;
1435
1442
  }
1436
- const name = getLastIdentifierFromMemberChain(call.callee);
1443
+ const name = getLastIdentifierFromMemberChain(resolvedCall.callee);
1437
1444
  if (!name) {
1438
1445
  return null;
1439
1446
  }
1440
- const suffix = getStableSuffixFromCall(call);
1447
+ const suffix = getStableSuffixFromCall(resolvedCall);
1441
1448
  const semanticNameHint = suffix ? `${toPascalCase(name)}${suffix}` : toPascalCase(name);
1442
1449
  return semanticNameHint;
1443
1450
  };