babel-helper-hoist-variables
Advanced tools
Comparing version 7.0.0-alpha.15 to 7.0.0-alpha.16
@@ -7,4 +7,6 @@ "use strict"; | ||
var kind = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : "var"; | ||
path.traverse(visitor, { kind: kind, emit: emit }); | ||
path.traverse(visitor, { | ||
kind: kind, | ||
emit: emit | ||
}); | ||
}; | ||
@@ -27,5 +29,3 @@ | ||
if (state.kind && path.node.kind !== state.kind) return; | ||
var nodes = []; | ||
var declarations = path.get("declarations"); | ||
@@ -47,3 +47,2 @@ var firstId = void 0; | ||
var declar = _ref; | ||
firstId = declar.node.id; | ||
@@ -60,3 +59,5 @@ | ||
if (path.parentPath.isFor({ left: path.node })) { | ||
if (path.parentPath.isFor({ | ||
left: path.node | ||
})) { | ||
path.replaceWith(firstId); | ||
@@ -63,0 +64,0 @@ } else { |
{ | ||
"name": "babel-helper-hoist-variables", | ||
"version": "7.0.0-alpha.15", | ||
"version": "7.0.0-alpha.16", | ||
"description": "Helper function to hoist variables", | ||
@@ -9,4 +9,4 @@ "repository": "https://github.com/babel/babel/tree/master/packages/babel-helper-hoist-variables", | ||
"dependencies": { | ||
"babel-types": "7.0.0-alpha.15" | ||
"babel-types": "7.0.0-alpha.16" | ||
} | ||
} |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
2246
51
+ Addedbabel-types@7.0.0-alpha.16(transitive)
+ Addedto-fast-properties@2.0.0(transitive)
- Removedbabel-types@7.0.0-alpha.15(transitive)
- Removedto-fast-properties@1.0.3(transitive)
Updatedbabel-types@7.0.0-alpha.16