babel-plugin-vasille 4.2.3 → 4.2.5

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.
Files changed (2) hide show
  1. package/lib/jsx.js +3 -2
  2. package/package.json +1 -1
package/lib/jsx.js CHANGED
@@ -109,10 +109,10 @@ function transformJsxArray(paths, internal) {
109
109
  }
110
110
  function statementsToFunction(arr) {
111
111
  if (arr.length == 1 && t.isExpressionStatement(arr[0])) {
112
- return t.arrowFunctionExpression([], arr[0].expression);
112
+ return t.arrowFunctionExpression([internal_js_1.ctx], arr[0].expression);
113
113
  }
114
114
  else {
115
- return t.arrowFunctionExpression([], t.blockStatement(arr));
115
+ return t.arrowFunctionExpression([internal_js_1.ctx], t.blockStatement(arr));
116
116
  }
117
117
  }
118
118
  function checkIfExpressionIsConditionalJsx(expr) {
@@ -476,6 +476,7 @@ function transformJsxElement(path, conditions, internal) {
476
476
  else {
477
477
  /* istanbul ignore else */
478
478
  if (expressionPath && expressionPath.isExpression()) {
479
+ (0, lib_js_1.exprCall)(expressionPath, expressionPath.node, internal, {});
479
480
  attrs.push(idToProp(name, expressionPath.node));
480
481
  }
481
482
  else if (t.isStringLiteral(attr.value)) {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "babel-plugin-vasille",
3
- "version": "4.2.3",
3
+ "version": "4.2.5",
4
4
  "description": "Convert Vasille Meta Language code to pure JavaScript",
5
5
  "main": "lib/index.js",
6
6
  "type": "commonjs",