-
-
Notifications
You must be signed in to change notification settings - Fork 27k
Add polyfill from polyfill.io #174
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
Conversation
Note that we lock to the current default feature set (default-3.6). Future versions of create-react-app will want to update this version number, but we wouldn't want users to inadvertently get different polyfills.
Why would that be bad? They’re only adding, not removing stuff, right? |
Probably/Mostly. They haven't committed to never removing anything from the default set. Although they haven't done so yet, it would have been reasonable at one point for them to include You can see what they say about this under https://polyfill.io/v2/docs/features/#default-sets |
How about we use this set? https://cdn.polyfill.io/v2/polyfill.js?features=es6,fetch,Symbol&unknown=polyfill This seems like the most valuable stuff in React apps, and also protects against issues like #561 with |
It’s also more descriptive than |
Also worth checking: does their Promise polyfill swallow errors. |
I don't think you can solve uncaught rejections in userland (polyfills). |
Why not? It won’t be 100% accurate but we need to err on the side of less head scratching. Advanced Promise users who know what they’re doing with temporarily unhandled rejections will just include another polyfill. |
Also core-js does this. |
We went with embedded fetch and Promise polyfills for now so closing. |
Note that we lock to the current default feature set (default-3.6). Future versions of create-react-app will want to update this version number, but we wouldn't want users to inadvertently get different polyfills.
[closes #170]