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

Lock babel configuration back to IE 9 support (ES5) #5033

Merged
merged 1 commit into from
Sep 19, 2018
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 9 additions & 1 deletion packages/babel-preset-react-app/create.js
Original file line number Diff line number Diff line change
Expand Up @@ -45,14 +45,22 @@ module.exports = function(api, opts, env) {
require('@babel/preset-env').default,
{
targets: {
node: '6.12',
node: 'current',
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This somehow got goofed during an old merge commit, but current is the behavior we want.

},
},
],
(isEnvProduction || isEnvDevelopment) && [
// Latest stable ECMAScript features
require('@babel/preset-env').default,
{
// We want Create React App to be IE 9 compatible until React itself
// no longer works with IE 9
targets: {
ie: 9,
},
// Users cannot override this behavior because this Babel
// configuration is highly tuned for ES5 support
ignoreBrowserslistConfig: true,
// `entry` transforms `@babel/polyfill` into individual requires for
// the targeted browsers. This is safer than `usage` which performs
// static code analysis to determine what's required.
Expand Down