Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fails when targets is defined in an unconventional way #465

Open
simonihmig opened this issue Oct 26, 2021 · 1 comment
Open

Fails when targets is defined in an unconventional way #465

simonihmig opened this issue Oct 26, 2021 · 1 comment

Comments

@simonihmig
Copy link
Contributor

Getting TypeError: Cannot read property 'join' of undefined thrown here when targets are defined without a browsers property (example). This has worked before, I assume targets is simply passed to @babel/preset-env which does support defining targets in a variety of formats

The format I used was suggested as a workaround for a Fastboot related transpilation issue.

I just checked the original RFC, and it does mention a browsers property specifically, so I guess this is then not necessarily a bug. But maybe people have used different formats in the wild as I did, so thought I should raise this here, at least for visibility...

@ef4
Copy link
Collaborator

ef4 commented Nov 14, 2021

The wrinkle here is that we don't just pass this to @babel/preset-env. We also pass it to webpack's target option here.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants