summaryrefslogtreecommitdiff
path: root/node_modules/@babel/preset-env/lib/index.js
diff options
context:
space:
mode:
Diffstat (limited to 'node_modules/@babel/preset-env/lib/index.js')
-rw-r--r--node_modules/@babel/preset-env/lib/index.js2
1 files changed, 1 insertions, 1 deletions
diff --git a/node_modules/@babel/preset-env/lib/index.js b/node_modules/@babel/preset-env/lib/index.js
index 4738175f..b1142d2c 100644
--- a/node_modules/@babel/preset-env/lib/index.js
+++ b/node_modules/@babel/preset-env/lib/index.js
@@ -250,7 +250,7 @@ option \`forceAllTransforms: true\` instead.
const compatData = getPluginList(shippedProposals, bugfixes);
const modules = optionsModules === "auto" ? api.caller(supportsStaticESM) ? false : "commonjs" : optionsModules;
const shouldTransformDynamicImport = optionsModules === "auto" ? !api.caller(supportsDynamicImport) : !!modules;
- if (optionsModules === "auto" && !api.caller(supportsExportNamespaceFrom) && !exclude.plugins.has("transform-export-namespace-from")) {
+ if (!exclude.plugins.has("transform-export-namespace-from") && (optionsModules === "auto" ? !api.caller(supportsExportNamespaceFrom) : !!modules)) {
include.plugins.add("transform-export-namespace-from");
}
const pluginNames = (0, _helperCompilationTargets.filterItems)(compatData, include.plugins, exclude.plugins, transformTargets, getSpecialModulesPluginNames(modules, shouldTransformDynamicImport), !loose ? undefined : ["transform-typeof-symbol"], _shippedProposals.pluginSyntaxMap);