@babel/helper-module-transforms
Advanced tools
Comparing version
@@ -238,3 +238,5 @@ "use strict"; | ||
const bindingKindLookup = new Map(); | ||
programPath.get("body").forEach(child => { | ||
const programScope = programPath.scope; | ||
const programChildren = programPath.get("body"); | ||
programChildren.forEach(child => { | ||
let kind; | ||
@@ -281,3 +283,4 @@ if (child.isImportDeclaration()) { | ||
if (!metadata) { | ||
const kind = bindingKindLookup.get(localName); | ||
var _bindingKindLookup$ge, _programScope$getBind; | ||
const kind = (_bindingKindLookup$ge = bindingKindLookup.get(localName)) != null ? _bindingKindLookup$ge : (_programScope$getBind = programScope.getBinding(localName)) == null ? void 0 : _programScope$getBind.kind; | ||
if (kind === undefined) { | ||
@@ -294,3 +297,3 @@ throw idPath.buildCodeFrameError(`Exporting local "${localName}", which is not declared.`); | ||
}; | ||
programPath.get("body").forEach(child => { | ||
programChildren.forEach(child => { | ||
if (child.isExportNamedDeclaration() && (initializeReexports || !child.node.source)) { | ||
@@ -297,0 +300,0 @@ if (child.node.declaration) { |
{ | ||
"name": "@babel/helper-module-transforms", | ||
"version": "7.27.1", | ||
"version": "7.27.3", | ||
"description": "Babel helper functions for implementing ES6 module transformations", | ||
@@ -20,6 +20,6 @@ "author": "The Babel Team (https://babel.dev/team)", | ||
"@babel/helper-validator-identifier": "^7.27.1", | ||
"@babel/traverse": "^7.27.1" | ||
"@babel/traverse": "^7.27.3" | ||
}, | ||
"devDependencies": { | ||
"@babel/core": "^7.27.1" | ||
"@babel/core": "^7.27.3" | ||
}, | ||
@@ -26,0 +26,0 @@ "peerDependencies": { |
Sorry, the diff of this file is not supported yet
161825
0.6%1256
0.24%- Removed
Updated