Skip to content

[babel] remove @babel/polyfill, make core-js devDep#1982

Merged
spalger merged 9 commits intoelastic:masterfrom
spalger:remove-core-js-prod
Jun 7, 2019
Merged

[babel] remove @babel/polyfill, make core-js devDep#1982
spalger merged 9 commits intoelastic:masterfrom
spalger:remove-core-js-prod

Conversation

@spalger
Copy link
Contributor

@spalger spalger commented May 30, 2019

Summary

It feels like we shouldn't be requiring core-js in eui, and should instead rely on the application to setup a polyfill that modifies globals. To do this i've followed the pattern used for customizing the babel es module config and disabled the uiBuiltIns: usage config when building for production.

This means that consumers of EUI need to use a polyfill of some sort (preferably core-js@3), which is why I've labeled this a breaking change, but in reality every consumer of eui should already be doing this it just wasn't explicitly required before.

Checklist

  • This was checked in mobile
  • This was checked in IE11
  • This was checked in dark mode
  • Any props added have proper autodocs
  • Documentation examples were added
  • A changelog entry exists and is marked appropriately
  • This was checked for breaking changes and labeled appropriately
  • Jest tests were updated or added to match the most common scenarios
  • This was checked against keyboard-only and screenreader scenarios
  • This required updates to Framer X components

@spalger spalger added the breaking change PRs with breaking changes. (Don't delete - used for automation) label May 30, 2019
Copy link
Contributor

@chandlerprall chandlerprall left a comment

Choose a reason for hiding this comment

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

One last change, otherwise everything looks good in the various cases I've put the this through.

@chandlerprall
Copy link
Contributor

chandlerprall commented Jun 3, 2019

CI had an http timeout

jenkins test this

Copy link
Contributor

@chandlerprall chandlerprall left a comment

Choose a reason for hiding this comment

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

Changes LGTM; ran build locally and verified core-js imports are removed as desired, and builds continue to run as expected.

@thompsongl
Copy link
Contributor

CI looks like its hanging again, but let's hold merging this until EUI@11.3.0 is released regardless

@spalger spalger requested a review from thompsongl June 6, 2019 20:55
Copy link
Contributor

@thompsongl thompsongl left a comment

Choose a reason for hiding this comment

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

CL in its right place

@spalger spalger merged commit b592ab5 into elastic:master Jun 7, 2019
@spalger spalger deleted the remove-core-js-prod branch June 7, 2019 00:08
spalger pushed a commit to elastic/kibana that referenced this pull request Jun 12, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

breaking change PRs with breaking changes. (Don't delete - used for automation)

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants