question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

babel-preset-react-app with babel-preset-env

See original GitHub issue

I see that creat-react-app includes the babel-preset-react-app plugin for babel. Can I use this plugin with babel-preset-env or is that not necessary? I am not really sure what babel-preset-react-app includes.

Issue Analytics

  • State:closed
  • Created 6 years ago
  • Comments:5 (1 by maintainers)

github_iconTop GitHub Comments

1reaction
Timercommented, Mar 5, 2018

It’s unnecessary as we already include it 😄. Take a peek at the source to see what it includes as advised above!

Please note that if you’re using CRA (react-scripts) configuring babel is unnecessary and will “just work” for any files in the src/ directory.

0reactions
alexcrooxcommented, Jul 18, 2018

@miraage doesn’t babel-preset-env use browserslist so you could add the key to your package.json to configure?

"browserslist": ["> 1%", "IE 10"]

Read more comments on GitHub >

github_iconTop Results From Across the Web

babel/preset-react
This preset always includes the following plugins: ... This is useful when combined with the env option configuration or js config files.
Read more >
babel-preset-react-app - npm
This package includes the Babel preset used by Create React App. Please refer to its documentation: Getting Started – How to create a...
Read more >
Configuring a React app using Webpack and Babel - Medium
Configuring babel ; babel-loader : allows transpiling JavaScript files using Babel and webpack. ; babel/preset-env: preset that allows you to use ...
Read more >
What is @babel/preset-env and why do I need it? - Jakob Lind
If you open output.js, you'll see that nothing has changed. It's exactly the same content as input.js. That's not what you expected, was...
Read more >
difference between preset-react and react in babel
ReactDOM.render(<App />, document.getElementById('root'));. So I changed .babelrc env file to "presets": [ "@babel/react", "@babel/env" ].
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found