Skip to content

Commit

Permalink
fix
Browse files Browse the repository at this point in the history
  • Loading branch information
nicolo-ribaudo committed Feb 25, 2021
1 parent 3615eac commit dda6659
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion packages/babel-helper-compilation-targets/src/index.js
Expand Up @@ -205,7 +205,7 @@ export default function getTargets(

// `esmodules` as a target indicates the specific set of browsers supporting ES Modules.
// These values OVERRIDE the `browsers` field.
if (esmodules && (esmodules !== "intersect" || !shouldParseBrowsers)) {
if (esmodules && (esmodules !== "intersect" || !browsers?.length)) {
browsers = Object.keys(ESM_SUPPORT)
.map(browser => `${browser} >= ${ESM_SUPPORT[browser]}`)
.join(", ");
Expand Down

0 comments on commit dda6659

Please sign in to comment.