Error when compiling with babel-webpack
See original GitHub issueHI @everyone
I’m getting some weird output after transpiled the library in webpack with babel.
Specifically, an Unexpected token: punc (:)
error on .[/~/debug/node.js:122,0]
Point is, it’s transpiling lines like:
122: process.env.DEBUG = namespaces;
into:
122: {"NODE_ENV":"production"}.DEBUG = namespaces;
Why would it transpile process.env
into that object?
Issue Analytics
- State:
- Created 7 years ago
- Reactions:2
- Comments:7 (3 by maintainers)
Top Results From Across the Web
Error when compiling with webpack and babel-loader
According to the error it seems that redux is complaining about the stage option. It is probably because redux is still using Babel...
Read more >Problem: Babel isn't compiling my code how I expected
I just setup my Webpack project but Babel isn't compiling the way it should!
Read more >Webpack Compilation Error: Cannot find module - Babel ...
Current behavior: The test doesn't start and an error message is displayed Desired behavior: Test work as they were in version 4.12 Test ......
Read more >babel-loader - webpack
core-js and webpack/buildin will cause errors if they are transpiled by Babel. You will need to exclude them form babel-loader . { "loader":...
Read more >Webpack build error - Questions - Babylon.js Forum
It's the “null coalescing operator” that you need to configure babel for. I wonder why Babylon doesn't target an older ES version, since...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
This workaround worked for us using the DefinePlugin.
Closing, since this is an issue with your webpack configuration, not with debug itself.