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

[KAIZEN-0] tvinger core-js til versjon 3.5.0 #1279

Merged
merged 1 commit into from
Jun 9, 2020
Merged

[KAIZEN-0] tvinger core-js til versjon 3.5.0 #1279

merged 1 commit into from
Jun 9, 2020

Conversation

nutgaard
Copy link
Contributor

@nutgaard nutgaard commented Jun 9, 2020

Gjøres pga følgende issues;
JakeChampion/fetch#750
JakeChampion/fetch#748
zloirock/core-js#751
zloirock/core-js#741

I bunn og grunn, core-js@^3.6.0 introduserte støtte for
String.prototype.split med regex som har sticky-flag. Pga bug her så
fungerer ikke funksjonen som forventet noe mer i eldre IE11 versjoner.

E.g "test".split(/e/) === ['t', 'e', 's', 't'], denne burde gitt
['t', 'st']

Gjøres pga følgende issues;
JakeChampion/fetch#750
JakeChampion/fetch#748
zloirock/core-js#751
zloirock/core-js#741

I bunn og grunn, core-js@^3.6.0 introduserte støtte for
String.prototype.split med regex som har sticky-flag. Pga bug her så
fungerer ikke funksjonen som forventet noe mer i eldre IE11 versjoner.

E.g `"test".split(/e/) === ['t', 'e', 's', 't']`, denne burde gitt
`['t', 'st']`
@nutgaard nutgaard requested a review from a team as a code owner June 9, 2020 11:16
import { configure } from 'enzyme';
import EnzymeReactAdapter from 'enzyme-adapter-react-16';
import 'jest-enzyme';
import 'babel-polyfill';
Copy link
Contributor

Choose a reason for hiding this comment

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

Så babel gjorde split.regex biten før? Nå går alt via core-js?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Dette er bare for test-biten, her ble babel-polyfill brukt slik at Array.prototype.flatMap etc skulle eksistere under test.
Men babel-polyfill har blitt deprecated til fordel for core-js, så bytter derfor om på det i test-sammenheng også.

Copy link
Contributor

Choose a reason for hiding this comment

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

Aha. Da skjønner jeg! Derfor fetch-mock også forsvinner?

@nutgaard nutgaard merged commit a75aee4 into master Jun 9, 2020
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

Successfully merging this pull request may close these issues.

2 participants