Skip to content

Commit 69825fd

Browse files
authored
Merge pull request #18 from humanchimp/issue/presets-targets
read from preset.options.targets instead of preset.targets
2 parents c25f3bb + 5daf2fe commit 69825fd

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/util/get-babel-config/get-babel-config.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -115,7 +115,7 @@ export function getBabelConfig({babelConfig, cwd, forcedOptions = {}, defaultOpt
115115
...FORCED_BABEL_PRESET_ENV_OPTIONS,
116116
// If targets have already been provided by the user options, accept them.
117117
// Otherwise, apply the browserslist as the preset-env target
118-
...(preset.targets != null
118+
...(preset.options != null && preset.options.targets != null
119119
? {}
120120
: {
121121
targets: {

0 commit comments

Comments
 (0)